|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.axonframework.integration.adapter.EventPublishingMessageChannelAdapter
public class EventPublishingMessageChannelAdapter
Adapter class that publishes Events from a Spring Integration Message Channel on the Event Bus. All events are expected to be contained in the payload of the Message instances.
Optionally, this adapter can be configured with a filter, which can block or accept messages based on their type.
| Constructor Summary | |
|---|---|
EventPublishingMessageChannelAdapter(EventBus eventBus)
Initialize the adapter to publish all incoming events to the given eventBus. |
|
EventPublishingMessageChannelAdapter(EventBus eventBus,
EventFilter filter)
Initialize the adapter to publish all incoming events to the given eventBus if they accepted by the
given filter. |
|
| Method Summary | |
|---|---|
void |
handleMessage(org.springframework.integration.Message<?> message)
Handles the given message. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EventPublishingMessageChannelAdapter(EventBus eventBus)
eventBus.
eventBus - The event bus to publish events on
public EventPublishingMessageChannelAdapter(EventBus eventBus,
EventFilter filter)
eventBus if they accepted by the
given filter.
eventBus - The event bus to publish events on.filter - The filter that indicates which events to publish.| Method Detail |
|---|
public void handleMessage(org.springframework.integration.Message<?> message)
message. The message is expected to contain an object of type EventMessage in its payload. If that is not the case, a MessageRejectedException is
thrown.
If the message does contain an EventMessage, but the filter
refuses
it, a MessageRejectedException is also thrown.
handleMessage in interface org.springframework.integration.core.MessageHandlermessage - The message containing the event to publish
org.springframework.integration.MessageRejectedException - is the payload could not be published on the event bus.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||