com.alibaba.rocketmq.common.message
类 Message

java.lang.Object
  继承者 com.alibaba.rocketmq.common.message.Message
所有已实现的接口:
Serializable
直接已知子类:
MessageExt

public class Message
extends Object
implements Serializable

消息,Producer与Consumer使用

从以下版本开始:
2013-7-18
作者:
shijia.wxr
另请参见:
序列化表格

构造方法摘要
Message()
           
Message(String topic, byte[] body)
           
Message(String topic, String tags, byte[] body)
           
Message(String topic, String tags, String keys, byte[] body)
           
Message(String topic, String tags, String keys, int flag, byte[] body, boolean waitStoreMsgOK)
           
 
方法摘要
 byte[] getBody()
           
 String getBuyerId()
           
 int getDelayTimeLevel()
           
 int getFlag()
           
 String getKeys()
           
 Map<String,String> getProperties()
           
 String getProperty(String name)
           
 String getTags()
           
 String getTopic()
           
 String getUserProperty(String name)
           
 boolean isWaitStoreMsgOK()
           
 void putUserProperty(String name, String value)
           
 void setBody(byte[] body)
           
 void setBuyerId(String buyerId)
           
 void setDelayTimeLevel(int level)
           
 void setFlag(int flag)
           
 void setKeys(Collection<String> keys)
           
 void setKeys(String keys)
           
 void setTags(String tags)
           
 void setTopic(String topic)
           
 void setWaitStoreMsgOK(boolean waitStoreMsgOK)
           
 String toString()
           
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

构造方法详细信息

Message

public Message()

Message

public Message(String topic,
               byte[] body)

Message

public Message(String topic,
               String tags,
               byte[] body)

Message

public Message(String topic,
               String tags,
               String keys,
               byte[] body)

Message

public Message(String topic,
               String tags,
               String keys,
               int flag,
               byte[] body,
               boolean waitStoreMsgOK)
方法详细信息

putUserProperty

public void putUserProperty(String name,
                            String value)

getUserProperty

public String getUserProperty(String name)

getProperty

public String getProperty(String name)

getTopic

public String getTopic()

setTopic

public void setTopic(String topic)

getTags

public String getTags()

setTags

public void setTags(String tags)

getKeys

public String getKeys()

setKeys

public void setKeys(String keys)

setKeys

public void setKeys(Collection<String> keys)

getDelayTimeLevel

public int getDelayTimeLevel()

setDelayTimeLevel

public void setDelayTimeLevel(int level)

isWaitStoreMsgOK

public boolean isWaitStoreMsgOK()

setWaitStoreMsgOK

public void setWaitStoreMsgOK(boolean waitStoreMsgOK)

getFlag

public int getFlag()

setFlag

public void setFlag(int flag)

getBody

public byte[] getBody()

setBody

public void setBody(byte[] body)

getProperties

public Map<String,String> getProperties()

setBuyerId

public void setBuyerId(String buyerId)

getBuyerId

public String getBuyerId()

toString

public String toString()
覆盖:
Object 中的 toString


Copyright © 2012-2015. All Rights Reserved.