Class CorrelationRuleFilter
correlation id
content type
subject
message id
reply-to
reply-to session id
session id
to
- or, any
user-defined properties
A match exists when an arriving message's value for a property is equal to the value specified in the correlation
filter. For string expressions, the comparison is case-sensitive. When specifying multiple match properties, the
filter combines them as a logical AND
condition, meaning all conditions must match for the filter to
match.
This provides an efficient shortcut for declarations of filters that deal only with correlation
equality. In this case the cost of the lexigraphical analysis of the expression can be avoided. Not only will
correlation filters be optimized at declaration time, but they will also be optimized at runtime. Correlation filter
matching can be reduced to a hashtable lookup, which aggregates the complexity of the set of defined correlation
filters to O(1)
.
-
Constructor Summary
ConstructorDescriptionInitializes a new instance ofCorrelationRuleFilter
with default values.CorrelationRuleFilter
(String correlationId) Initializes a new instance ofCorrelationRuleFilter
with default values with the specified correlation identifier. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Compares this RuleFilter to the specified object.Gets the content type of the message.Gets the correlation identifier.getLabel()
Gets the application specific label.Gets the identifier for the message.Gets application specific properties of the message.Gets the address of the queue or subscription to reply to.Gets the session identifier to reply to.Gets the session identifier.getTo()
Gets the address to send to.int
hashCode()
Returns a hash code for this CorrelationRuleFilter.setContentType
(String contentType) Sets the content type of the message.setCorrelationId
(String correlationId) Sets the correlation identifier.Sets the application specific label.setMessageId
(String messageId) Sets the identifier for the message.setReplyTo
(String replyTo) Sets the address of the queue or subscription to reply to.setReplyToSessionId
(String replyToSessionId) Sets the session identifier to reply to.setSessionId
(String sessionId) Sets the session identifier.Sets the address to send to.toString()
Converts the value of the current instance to its equivalent string representation.
-
Constructor Details
-
CorrelationRuleFilter
public CorrelationRuleFilter()Initializes a new instance ofCorrelationRuleFilter
with default values. -
CorrelationRuleFilter
Initializes a new instance ofCorrelationRuleFilter
with default values with the specified correlation identifier.- Parameters:
correlationId
- The identifier for the correlation.- Throws:
IllegalArgumentException
- IfcorrelationId
is an empty string.NullPointerException
- IfcorrelationId
is null.
-
-
Method Details
-
getContentType
Gets the content type of the message.- Returns:
- The content type of the message.
-
setContentType
Sets the content type of the message.- Parameters:
contentType
- The content type of the message.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getCorrelationId
Gets the correlation identifier.- Returns:
- The correlation identifier.
-
setCorrelationId
Sets the correlation identifier.- Parameters:
correlationId
- The correlation identifier.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getLabel
Gets the application specific label.- Returns:
- The application specific label.
-
setLabel
Sets the application specific label.- Parameters:
label
- The application specific label.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getMessageId
Gets the identifier for the message.- Returns:
- The identifier for the message.
-
setMessageId
Sets the identifier for the message.- Parameters:
messageId
- The identifier for the message.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getProperties
Gets application specific properties of the message.- Returns:
- The application specific properties of the message.
-
getReplyTo
Gets the address of the queue or subscription to reply to.- Returns:
- The address of the queue or subscription to reply to.
-
setReplyTo
Sets the address of the queue or subscription to reply to.- Parameters:
replyTo
- The address of the queue or subscription to reply to.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getReplyToSessionId
Gets the session identifier to reply to.- Returns:
- The session identifier to reply to.
-
setReplyToSessionId
Sets the session identifier to reply to. Max size ofreplyToSessionId
is 128.- Parameters:
replyToSessionId
- The session identifier to reply to.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getSessionId
Gets the session identifier.- Returns:
- The session identifier.
-
setSessionId
Sets the session identifier. Max size ofsessionId
is 128 chars.- Parameters:
sessionId
- The session identifier.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
getTo
Gets the address to send to.- Returns:
- The address to send to.
-
setTo
Sets the address to send to.- Parameters:
to
- The address to send to.- Returns:
- The updated
CorrelationRuleFilter
itself.
-
toString
Converts the value of the current instance to its equivalent string representation. -
equals
Compares this RuleFilter to the specified object. The result is true if and only if the argument is not null and is a CorrelationRuleFilter object that with the same parameters as this object. -
hashCode
public int hashCode()Returns a hash code for this CorrelationRuleFilter.
-