com.alibaba.rocketmq.client
类 Validators

java.lang.Object
  继承者 com.alibaba.rocketmq.client.Validators

public class Validators
extends Object

有效性检查公用类。

从以下版本开始:
2013-8-28
作者:
manhong.yqd

字段摘要
static int CHARACTER_MAX_LENGTH
           
static String validPatternStr
           
 
构造方法摘要
Validators()
           
 
方法摘要
static void checkGroup(String group)
          group 有效性检查
static void checkMessage(Message msg, DefaultMQProducer defaultMQProducer)
          message 有效性检查
static void checkTopic(String topic)
          topic 有效性检查
static String getGroupWithRegularExpression(String origin, String patternStr)
          通过正则表达式查找匹配的字符
static boolean regularExpressionMatcher(String origin, String patternStr)
          通过正则表达式进行字符匹配
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

validPatternStr

public static final String validPatternStr
另请参见:
常量字段值

CHARACTER_MAX_LENGTH

public static final int CHARACTER_MAX_LENGTH
另请参见:
常量字段值
构造方法详细信息

Validators

public Validators()
方法详细信息

regularExpressionMatcher

public static boolean regularExpressionMatcher(String origin,
                                               String patternStr)
通过正则表达式进行字符匹配

参数:
origin -
patternStr -
返回:

getGroupWithRegularExpression

public static String getGroupWithRegularExpression(String origin,
                                                   String patternStr)
通过正则表达式查找匹配的字符

参数:
origin -
patternStr -
返回:

checkTopic

public static void checkTopic(String topic)
                       throws MQClientException
topic 有效性检查

参数:
topic -
抛出:
MQClientException

checkGroup

public static void checkGroup(String group)
                       throws MQClientException
group 有效性检查

参数:
group -
抛出:
MQClientException

checkMessage

public static void checkMessage(Message msg,
                                DefaultMQProducer defaultMQProducer)
                         throws MQClientException
message 有效性检查

参数:
msg -
defaultMQProducer -
抛出:
MQClientException


Copyright © 2012-2014. All Rights Reserved.