Interface Declarable
- All Known Subinterfaces:
- Exchange
- All Known Implementing Classes:
- AbstractDeclarable,- AbstractExchange,- AnonymousQueue,- Binding,- ConsistentHashExchange,- CustomExchange,- DirectExchange,- FanoutExchange,- HeadersExchange,- Queue,- TopicExchange
public interface Declarable
Classes implementing this interface can be auto-declared
 with the broker during context initialization by an 
AmqpAdmin.
 Registration can be limited to specific AmqpAdmins.- Since:
- 1.2
- Author:
- Gary Russell
- 
Method SummaryModifier and TypeMethodDescriptiondefault voidaddArgument(String name, Object value) Add an argument to the declarable.Collection<?> The collection ofAmqpAdmins that should declare this object; if empty, all admins should declare.booleanShould ignore exceptions (such as mismatched args) when declaring.default ObjectremoveArgument(String name) Remove an argument from the declarable.voidsetAdminsThatShouldDeclare(Object... adminArgs) TheAmqpAdmins that should declare this object; default is all admins.booleanWhether or not this object should be automatically declared by anyAmqpAdmin.
- 
Method Details- 
shouldDeclareboolean shouldDeclare()Whether or not this object should be automatically declared by anyAmqpAdmin.- Returns:
- true if the object should be declared.
 
- 
getDeclaringAdminsCollection<?> getDeclaringAdmins()The collection ofAmqpAdmins that should declare this object; if empty, all admins should declare.- Returns:
- the collection.
 
- 
isIgnoreDeclarationExceptionsboolean isIgnoreDeclarationExceptions()Should ignore exceptions (such as mismatched args) when declaring.- Returns:
- true if should ignore.
- Since:
- 1.6
 
- 
setAdminsThatShouldDeclareTheAmqpAdmins that should declare this object; default is all admins.
 A null argument, or an array/varArg with a single null argument, clears the collection (setAdminsThatShouldDeclare((AmqpAdmin) null)orsetAdminsThatShouldDeclare((AmqpAdmin[]) null)). Clearing the collection resets the behavior such that all admins will declare the object.- Parameters:
- adminArgs- The admins.
 
- 
addArgument
- 
removeArgument
 
-