public class MsgConvertUtil extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
static String |
COMPATIBLE_FIELD_MSGMODEL
To adapt this scene: "Notify client try to receive ObjectMessage sent by JMS client"
Set notify out message model, value can be textMessage OR objectMessage
|
static byte[] |
emptyBytes |
static String |
emptyString |
static String |
JMS_MSGMODEL |
static String |
MSG_TOPIC |
static String |
MSG_TYPE |
static String |
MSGMODEL_BYTES |
static String |
MSGMODEL_OBJ |
static String |
MSGMODEL_TEXT |
| 构造器和说明 |
|---|
MsgConvertUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static String |
bytes2String(byte[] bs,
String charset) |
static Serializable |
objectDeserialize(byte[] bytes) |
static byte[] |
objectSerialize(Object object) |
static byte[] |
string2Bytes(String s,
String charset) |
public static final byte[] emptyBytes
public static final String COMPATIBLE_FIELD_MSGMODEL
public static byte[] objectSerialize(Object object) throws IOException
IOExceptionpublic static Serializable objectDeserialize(byte[] bytes) throws IOException, ClassNotFoundException
Copyright © 2012-2016. All Rights Reserved.