本文整理了Java中org.apache.activemq.artemis.api.core.Message.getAnnotation()
方法的一些代码示例,展示了Message.getAnnotation()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Message.getAnnotation()
方法的具体详情如下:
包路径:org.apache.activemq.artemis.api.core.Message
类名称:Message
方法名:getAnnotation
暂无
代码示例来源:origin: wildfly/wildfly
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: wildfly/wildfly
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: apache/activemq-artemis
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: org.apache.activemq/artemis-core-client
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: org.apache.activemq/artemis-core-client
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: apache/activemq-artemis
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: apache/activemq-artemis
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: apache/activemq-artemis
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: apache/activemq-artemis
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: apache/activemq-artemis
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: org.apache.activemq/artemis-jms-client-all
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: org.jboss.eap/wildfly-client-all
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
代码示例来源:origin: org.jboss.eap/wildfly-client-all
default void referenceOriginalMessage(final Message original, String originalQueue) {
String queueOnMessage = original.getAnnotationString(Message.HDR_ORIGINAL_QUEUE);
if (queueOnMessage != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, queueOnMessage);
} else if (originalQueue != null) {
setAnnotation(Message.HDR_ORIGINAL_QUEUE, originalQueue);
}
Object originalID = original.getAnnotation(Message.HDR_ORIG_MESSAGE_ID);
if (originalID != null) {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAnnotationString(Message.HDR_ORIGINAL_ADDRESS));
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, originalID);
} else {
setAnnotation(Message.HDR_ORIGINAL_ADDRESS, original.getAddress());
setAnnotation(Message.HDR_ORIG_MESSAGE_ID, original.getMessageID());
}
// reset expiry
setExpiration(0);
}
代码示例来源:origin: org.apache.activemq/artemis-jms-client-all
default String getAnnotationString(SimpleString key) {
Object value = getAnnotation(key);
if (value != null) {
return value.toString();
} else {
return null;
}
}
内容来源于网络,如有侵权,请联系作者删除!