org.apache.qpid.server.exchange
Class HeadersBinding

java.lang.Object
  extended by org.apache.qpid.server.exchange.HeadersBinding

 class HeadersBinding
extends Object

Defines binding and matching based on a set of headers.


Constructor Summary
HeadersBinding(Binding binding)
          Creates a header binding for a set of mappings.
 
Method Summary
 boolean equals(Object o)
           
 Binding getBinding()
           
protected  org.apache.qpid.framing.FieldTable getMappings()
           
(package private) static boolean isSpecial(Object key)
           
(package private) static boolean isSpecial(String key)
           
 boolean matches(AMQMessageHeader headers)
          Checks whether the supplied headers match the requirements of this binding
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HeadersBinding

public HeadersBinding(Binding binding)
Creates a header binding for a set of mappings. Those mappings whose value is null or the empty string are assumed only to be required headers, with no constraint on the value. Those with a non-null value are assumed to define a required match of value.

Parameters:
binding - the binding to create a header binding using
Method Detail

getMappings

protected org.apache.qpid.framing.FieldTable getMappings()

getBinding

public Binding getBinding()

matches

public boolean matches(AMQMessageHeader headers)
Checks whether the supplied headers match the requirements of this binding

Parameters:
headers - the headers to check
Returns:
true if the headers define any required keys and match any required values

isSpecial

static boolean isSpecial(Object key)

isSpecial

static boolean isSpecial(String key)

equals

public boolean equals(Object o)
Overrides:
equals in class Object


Licensed to the Apache Software Foundation