public class MBassador<T> extends AbstractSyncAsyncMessageBus<T,SyncAsyncPostCommand<T>> implements IMessageBus<T,SyncAsyncPostCommand<T>>
ERROR_HANDLER_MSG
Constructor and Description |
---|
MBassador()
Default constructor using default setup.
|
MBassador(BusConfiguration configuration)
Construct with fully specified configuration
|
MBassador(IPublicationErrorHandler errorHandler)
Construct with default settings and specified publication error handler
|
Modifier and Type | Method and Description |
---|---|
SyncAsyncPostCommand<T> |
post(T message)
Publish a message to the bus using on of its supported message publication mechanisms.
|
IMessagePublication |
publish(T message)
Synchronously publish a message to all registered listeners (this includes listeners defined for super types)
The call blocks until every messageHandler has processed the message.
|
IMessagePublication |
publishAsync(T message) |
IMessagePublication |
publishAsync(T message,
long timeout,
TimeUnit unit) |
hasPendingMessages, shutdown
getRegisteredErrorHandlers, getRuntime, subscribe, toString, unsubscribe
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
hasPendingMessages, shutdown
subscribe, unsubscribe
getRuntime
getRegisteredErrorHandlers
public MBassador()
public MBassador(IPublicationErrorHandler errorHandler)
errorHandler
- public MBassador(BusConfiguration configuration)
configuration
- public IMessagePublication publishAsync(T message)
public IMessagePublication publishAsync(T message, long timeout, TimeUnit unit)
public IMessagePublication publish(T message)
publish
in interface PubSubSupport<T>
message
- public SyncAsyncPostCommand<T> post(T message)
IMessageBus
post
in interface GenericMessagePublicationSupport<T,SyncAsyncPostCommand<T>>
post
in interface IMessageBus<T,SyncAsyncPostCommand<T>>
message
- - Any subtype of T welcomeCopyright © 2018. All rights reserved.