Package com.trafficparrot.sdk.messaging
Class Destination
java.lang.Object
com.trafficparrot.sdk.messaging.Destination
- All Implemented Interfaces:
Comparable<Destination>
- Direct Known Subclasses:
Destination
A messaging destination (queue or topic) identified by name and type.
This is the canonical location for Destination.
The deprecated Destination extends this class
for backward compatibility - existing SDK plugins continue to work unchanged.
-
Field Summary
FieldsModifier and TypeFieldDescriptionFor an AMQP broker, the arguments Traffic Parrot declares the destination with; empty when there are none.final StringThe name of the queue or topic.final booleanFor an AMQP broker, whether Traffic Parrot leaves the destination undeclared on the broker.final DestinationTypeWhether it is a queue or a topic:DestinationType.QUEUEorDestinationType.TOPIC. -
Constructor Summary
ConstructorsConstructorDescriptionDestination(String name, DestinationType type) Creates a destination that is declared on an AMQP broker with no arguments, which is what a transformer usually wants:new Destination("orders.reply", DestinationType.QUEUE).Destination(String name, DestinationType type, boolean skipDeclare, Map<String, Object> declareArguments) Creates a destination with every field a mapping file can set. -
Method Summary
-
Field Details
-
name
The name of the queue or topic. For file messages, the path of the directory. -
type
Whether it is a queue or a topic:DestinationType.QUEUEorDestinationType.TOPIC. -
skipDeclare
public final boolean skipDeclareFor an AMQP broker, whether Traffic Parrot leaves the destination undeclared on the broker. It means nothing for IBM MQ and for file messages. -
declareArguments
For an AMQP broker, the arguments Traffic Parrot declares the destination with; empty when there are none. The map cannot be changed.
-
-
Constructor Details
-
Destination
Creates a destination that is declared on an AMQP broker with no arguments, which is what a transformer usually wants:new Destination("orders.reply", DestinationType.QUEUE).- Parameters:
name- the name of the queue or topictype- whether it is a queue or a topic
-
Destination
public Destination(String name, DestinationType type, boolean skipDeclare, Map<String, Object> declareArguments) Creates a destination with every field a mapping file can set.- Parameters:
name- the name of the queue or topictype- whether it is a queue or a topicskipDeclare- for an AMQP broker, true to leave the destination undeclared on the brokerdeclareArguments- for an AMQP broker, the arguments to declare the destination with; null for none
-
-
Method Details
-
equals
-
hashCode
public int hashCode() -
toString
-
compareTo
- Specified by:
compareToin interfaceComparable<Destination>
-