public enum ProtocolError extends java.lang.Enum<ProtocolError>
枚举常量和说明 |
---|
BODY_FORMAT_INCORRECT
BODY_FORMAT_INCORRECT
|
COMMIT_STATUS_INVALID
COMMIT_STATUS_INVALID
|
CONSUME_MODE_INVALID
CONSUME_MODE_INVALID
|
MESSAGE_HANDLER_INCORRECT
MESSAGE_HANDLER_INCORRECT
|
限定符和类型 | 方法和说明 |
---|---|
static ProtocolException |
bodyFormatIncorrect(java.lang.String msg)
body格式不正确错误
|
static ProtocolException |
commitStatusInvalid(java.lang.String msg)
提交状态不正确异常
|
static ProtocolException |
consumeModeInvalid(int consumeMode)
消费实例模式不正确
|
static ProtocolException |
createProtocolException(ProtocolError error,
java.lang.Object... args)
create 异常
|
static ProtocolException |
messageHandlerInvalid(java.lang.String handler)
消息Handler格式不正确
|
static ProtocolError |
valueOf(java.lang.String name)
返回带有指定名称的该类型的枚举常量。
|
static ProtocolError[] |
values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
public static final ProtocolError COMMIT_STATUS_INVALID
public static final ProtocolError CONSUME_MODE_INVALID
public static final ProtocolError BODY_FORMAT_INCORRECT
public static final ProtocolError MESSAGE_HANDLER_INCORRECT
public static ProtocolError[] values()
for (ProtocolError c : ProtocolError.values()) System.out.println(c);
public static ProtocolError valueOf(java.lang.String name)
name
- 要返回的枚举常量的名称。java.lang.IllegalArgumentException
- 如果该枚举类型没有带有指定名称的常量java.lang.NullPointerException
- 如果参数为空值public static ProtocolException bodyFormatIncorrect(java.lang.String msg)
msg
- 错误描述public static ProtocolException commitStatusInvalid(java.lang.String msg)
msg
- msgpublic static ProtocolException consumeModeInvalid(int consumeMode)
consumeMode
- consumeModepublic static ProtocolException messageHandlerInvalid(java.lang.String handler)
handler
- handlerpublic static ProtocolException createProtocolException(ProtocolError error, java.lang.Object... args)
error
- errorargs
- args