Package net.engio.mbassy.subscription
Class SubscriptionContext
java.lang.Object
net.engio.mbassy.subscription.SubscriptionContext
- All Implemented Interfaces:
RuntimeProvider
The subscription context holds all (meta)data/objects that are relevant to successfully publish
a message within a subscription. A one-to-one relation between a subscription and
subscription context holds -> a subscription context is created for each distinct subscription
managed by the subscription manager.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Collection
<IPublicationErrorHandler> private final MessageHandler
private final BusRuntime
-
Constructor Summary
ConstructorsConstructorDescriptionSubscriptionContext
(BusRuntime runtime, MessageHandler handler, Collection<IPublicationErrorHandler> errorHandlers) -
Method Summary
Modifier and TypeMethodDescriptionGet the error handlers registered with the enclosing bus.Get the meta data that specifies the characteristics of the message handler that is associated with this contextfinal void
handleError
(PublicationError error)
-
Field Details
-
handler
-
errorHandlers
-
runtime
-
-
Constructor Details
-
SubscriptionContext
public SubscriptionContext(BusRuntime runtime, MessageHandler handler, Collection<IPublicationErrorHandler> errorHandlers)
-
-
Method Details
-
getHandler
Get the meta data that specifies the characteristics of the message handler that is associated with this context -
getErrorHandlers
Get the error handlers registered with the enclosing bus. -
getRuntime
- Specified by:
getRuntime
in interfaceRuntimeProvider
-
handleError
-