Errai 3.0.1-SNAPSHOT

org.jboss.errai.cdi.server.events
Class EventDispatcher

java.lang.Object
  extended by org.jboss.errai.cdi.server.events.EventDispatcher
All Implemented Interfaces:
MessageCallback

public class EventDispatcher
extends Object
implements MessageCallback

Acts as a bridge between Errai Bus and the CDI event system.

Author:
Mike Brock, Christian Sadilek , Jonathan Fuerth

Constructor Summary
EventDispatcher(javax.enterprise.inject.spi.BeanManager beanManager, EventRoutingTable eventRoutingTable, MessageBus messageBus, Set<String> observedEvents, Map<String,Annotation> qualifiers, javax.enterprise.inject.spi.AfterBeanDiscovery afterBeanDiscovery)
           
 
Method Summary
 void callback(Message message)
          Called by the Message Bus every time it processes a message with the subject this callback is registered for.
 boolean isRoutable(LocalContext localContext, Message message)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EventDispatcher

public EventDispatcher(javax.enterprise.inject.spi.BeanManager beanManager,
                       EventRoutingTable eventRoutingTable,
                       MessageBus messageBus,
                       Set<String> observedEvents,
                       Map<String,Annotation> qualifiers,
                       javax.enterprise.inject.spi.AfterBeanDiscovery afterBeanDiscovery)
Method Detail

callback

public void callback(Message message)
Description copied from interface: MessageCallback
Called by the Message Bus every time it processes a message with the subject this callback is registered for.

Specified by:
callback in interface MessageCallback
Parameters:
message - The message on the bus. Avoid making changes to this object, because it will continue to be reused by the framework and the same Message instance will be passed to other callbacks.

isRoutable

public boolean isRoutable(LocalContext localContext,
                          Message message)

Errai 3.0.1-SNAPSHOT

Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.