org.jboss.errai.enterprise.client.cdi.api
Class CDI
java.lang.Object
org.jboss.errai.enterprise.client.cdi.api.CDI
public class CDI
- extends Object
CDI client interface.
- Author:
- Heiko Braun , Christian Sadilek , Mike Brock
Constructor Summary |
CDI()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CDI_SUBJECT_PREFIX
public static final String CDI_SUBJECT_PREFIX
- See Also:
- Constant Field Values
CDI_SERVICE_SUBJECT_PREFIX
public static final String CDI_SERVICE_SUBJECT_PREFIX
- See Also:
- Constant Field Values
SERVER_DISPATCHER_SUBJECT
public static final String SERVER_DISPATCHER_SUBJECT
- See Also:
- Constant Field Values
CLIENT_DISPATCHER_SUBJECT
public static final String CLIENT_DISPATCHER_SUBJECT
- See Also:
- Constant Field Values
ROUTING_CALLBACK
public static final MessageCallback ROUTING_CALLBACK
CDI
public CDI()
getSubjectNameByType
public static String getSubjectNameByType(String typeName)
__resetSubsystem
public void __resetSubsystem()
- Should only be called by bootstrapper for testing purposes.
initLookupTable
public void initLookupTable(CDIEventTypeLookup lookup)
getQualifiersPart
public static Set<String> getQualifiersPart(Annotation[] qualifiers)
- Return a list of string representations for the qualifiers.
- Parameters:
qualifiers
- -
- Returns:
fireEvent
public static void fireEvent(Object payload,
Annotation... qualifiers)
fireEvent
public static void fireEvent(boolean local,
Object payload,
Annotation... qualifiers)
subscribeLocal
public static Subscription subscribeLocal(String eventType,
AbstractCDIEventCallback<?> callback)
subscribe
public static Subscription subscribe(String eventType,
AbstractCDIEventCallback<?> callback)
resendSubscriptionRequestForAllEventTypes
public static void resendSubscriptionRequestForAllEventTypes()
- Informs the server of all active CDI observers currently registered on the
client. This is not strictly necessary when the client bus first connects,
because observers register themselves with the server as they are created.
However, if the QueueSession expires and the bus reconnects, it is
essential to inform the server of all existing CDI observers so the
server-side event routing can be established for the new session.
Application code should never have to call this method directly. The Errai
framework calls this method when required.
consumeEventFromMessage
public static void consumeEventFromMessage(Message message)
addRemoteEventType
public static void addRemoteEventType(String remoteEvent)
addRemoteEventTypes
public static void addRemoteEventTypes(String[] remoteEvent)
addPostInitTask
public static void addPostInitTask(Runnable runnable)
activate
public static void activate(String... remoteTypes)
Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.