本文整理了Java中org.apache.activemq.artemis.api.core.Message.removeProperty()
方法的一些代码示例,展示了Message.removeProperty()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Message.removeProperty()
方法的具体详情如下:
包路径:org.apache.activemq.artemis.api.core.Message
类名称:Message
方法名:removeProperty
暂无
代码示例来源:origin: wildfly/wildfly
default byte[] removeExtraBytesProperty(SimpleString key) throws ActiveMQPropertyConversionException {
return (byte[])removeProperty(key);
}
代码示例来源:origin: wildfly/wildfly
default Object removeAnnotation(SimpleString key) {
return removeProperty(key);
}
代码示例来源:origin: wildfly/wildfly
public static void setJMSReplyTo(Message message, final String dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: wildfly/wildfly
public static void setJMSReplyTo(Message message, final SimpleString dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: wildfly/wildfly
private static void replaceDict(final Message message, Map<SimpleString, SimpleString> dictionary) {
for (SimpleString property : new HashSet<>(message.getPropertyNames())) {
SimpleString replaceTo = dictionary.get(property);
if (replaceTo != null) {
message.putObjectProperty(replaceTo, message.removeProperty(property));
}
}
}
代码示例来源:origin: wildfly/wildfly
public static void setJMSCorrelationID(Message message, final String correlationID) {
if (correlationID == null) {
message.removeProperty(CORRELATIONID_HEADER_NAME);
} else {
message.putStringProperty(CORRELATIONID_HEADER_NAME, new SimpleString(correlationID));
}
}
代码示例来源:origin: wildfly/wildfly
public static void clearProperties(Message message) {
/**
* JavaDoc for this method states:
* Clears a message's properties.
* The message's header fields and body are not cleared.
*
* Since the {@code Message.HDR_ROUTING_TYPE} is used for the JMSDestination header it isn't cleared
*/
List<SimpleString> toRemove = new ArrayList<>();
for (SimpleString propName : message.getPropertyNames()) {
if ((!propName.startsWith(JMS) || propName.startsWith(JMSX) ||
propName.startsWith(JMS_)) && !propName.equals(Message.HDR_ROUTING_TYPE)) {
toRemove.add(propName);
}
}
for (SimpleString propName : toRemove) {
message.removeProperty(propName);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final SimpleString dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final String dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final String dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: org.apache.activemq/artemis-core-client
public static void setJMSReplyTo(Message message, final String dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final SimpleString dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: org.apache.activemq/artemis-core-client
public static void setJMSReplyTo(Message message, final SimpleString dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final String dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSReplyTo(Message message, final SimpleString dest) {
if (dest == null) {
message.removeProperty(REPLYTO_HEADER_NAME);
} else {
message.putStringProperty(REPLYTO_HEADER_NAME, dest);
}
}
代码示例来源:origin: apache/activemq-artemis
private static void replaceDict(final Message message, Map<SimpleString, SimpleString> dictionary) {
for (SimpleString property : new HashSet<>(message.getPropertyNames())) {
SimpleString replaceTo = dictionary.get(property);
if (replaceTo != null) {
message.putObjectProperty(replaceTo, message.removeProperty(property));
}
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSCorrelationID(Message message, final String correlationID) {
if (correlationID == null) {
message.removeProperty(CORRELATIONID_HEADER_NAME);
} else {
message.putStringProperty(CORRELATIONID_HEADER_NAME, new SimpleString(correlationID));
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSCorrelationID(Message message, final String correlationID) {
if (correlationID == null) {
message.removeProperty(CORRELATIONID_HEADER_NAME);
} else {
message.putStringProperty(CORRELATIONID_HEADER_NAME, new SimpleString(correlationID));
}
}
代码示例来源:origin: apache/activemq-artemis
public static void setJMSCorrelationID(Message message, final String correlationID) {
if (correlationID == null) {
message.removeProperty(CORRELATIONID_HEADER_NAME);
} else {
message.putStringProperty(CORRELATIONID_HEADER_NAME, new SimpleString(correlationID));
}
}
代码示例来源:origin: org.apache.activemq/artemis-jms-client-all
public static void setJMSCorrelationID(Message message, final String correlationID) {
if (correlationID == null) {
message.removeProperty(CORRELATIONID_HEADER_NAME);
} else {
message.putStringProperty(CORRELATIONID_HEADER_NAME, new SimpleString(correlationID));
}
}
内容来源于网络,如有侵权,请联系作者删除!