public class BusConfiguration extends Object implements IBusConfiguration
IBusConfiguration.Properties| Constructor and Description |
|---|
BusConfiguration() |
| Modifier and Type | Method and Description |
|---|---|
IBusConfiguration |
addFeature(Feature feature)
Add a feature to the given configuration, replacing any existing feature of the same type.
|
BusConfiguration |
addPublicationErrorHandler(IPublicationErrorHandler handler)
Add a handler that will be called whenever a publication error occurs.
|
<T extends Feature> |
getFeature(Class<T> feature)
Get a registered feature by its type (class).
|
<T> T |
getProperty(String name,
T defaultValue)
Read a property from this configuration.
|
Collection<IPublicationErrorHandler> |
getRegisteredPublicationErrorHandlers()
Get an unmodifiable collection of all registered publication error handlers
|
boolean |
hasProperty(String name)
Check whether a property has been set.
|
IBusConfiguration |
setProperty(String name,
Object value)
Set a property which will be read by the message bus constructor.
|
public IBusConfiguration setProperty(String name, Object value)
IBusConfigurationtrue even if set to null).setProperty in interface IBusConfigurationname - The name of the property. Note: Each implementation may support different properties.value - The value of the property.this bus configuration.public <T> T getProperty(String name, T defaultValue)
IBusConfigurationgetProperty in interface IBusConfigurationT - The type of propertyname - The name of the property to be read.defaultValue - The value to be returned if property was not founddefaultValue if not presentpublic boolean hasProperty(String name)
IBusConfigurationhasProperty in interface IBusConfigurationpublic <T extends Feature> T getFeature(Class<T> feature)
IBusConfigurationgetFeature in interface IBusConfigurationpublic IBusConfiguration addFeature(Feature feature)
IBusConfigurationaddFeature in interface IBusConfigurationfeature - The feature to addthis bus configuration.public final BusConfiguration addPublicationErrorHandler(IPublicationErrorHandler handler)
IBusConfigurationPublicationErroraddPublicationErrorHandler in interface IBusConfigurationhandler - The handler to be added to the list of handlersthis bus configuration.public Collection<IPublicationErrorHandler> getRegisteredPublicationErrorHandlers()
IBusConfigurationgetRegisteredPublicationErrorHandlers in interface IBusConfigurationCopyright © 2016. All rights reserved.