|
Platform SDK Java 8.5 API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.genesyslab.platform.applicationblocks.commons.broker.BrokerServiceBase<T>
setMessageHandler(handler)
to handle incoming messages asynchronously.
@Deprecated public class BrokerServiceBase<T>
BrokerServiceBase
class implements the Publish/Subscribe pattern.
Constructor Summary | |
---|---|
|
BrokerServiceBase()
Deprecated. |
protected |
BrokerServiceBase(int capacity)
Deprecated. |
Method Summary | |
---|---|
protected void |
notify(T obj)
Deprecated. Calls subscribers' processing/handling methods of to process publishing event. |
protected void |
onNotificationException(Subscriber<T> subscriber,
java.lang.Exception e)
Deprecated. Allows to handle exceptions thrown by subscribers' publishing event processing methods. |
protected void |
onPublish(T obj)
Deprecated. Event handler called when publish is initiated. |
void |
publish(T obj)
Deprecated. Publishes an event. |
void |
register(Action<T> handler,
Predicate<T> filter)
Deprecated. Subscribes an action to be performed when a publishing event occurs. |
void |
register(Subscriber<T> subscriber)
Deprecated. Registers a subscriber for notifications about and processing of publishing events. |
protected void |
switchSubscribersList(java.util.List<Subscriber<T>> newList)
Deprecated. It is sometimes needed to switch the type of the list holding subscribers. |
void |
unregister(Action<T> handler)
Deprecated. Unregisters a subscriber from notifications about publishing activities. |
void |
unregister(Subscriber<T> subscriber)
Deprecated. Unregisters a subscriber from notifications about publishing activities. |
protected void |
unregisterAll()
Deprecated. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BrokerServiceBase()
@Deprecated protected BrokerServiceBase(int capacity)
Method Detail |
---|
public void publish(T obj)
publish
in interface PublishingService<T>
obj
- Object that is used for event processingprotected void onPublish(T obj)
obj
- Object that is used for a publishing event processingpublic void register(Subscriber<T> subscriber)
register
in interface SubscriptionService<T>
subscriber
- subscriber object being registeredpublic void register(Action<T> handler, Predicate<T> filter)
register
in interface SubscriptionService<T>
handler
- the method that performs an action on the specified object
when a publishing event occursfilter
- Filter predicate that allows checking whether publishing event
should be processed or ignoredpublic void unregister(Subscriber<T> subscriber)
unregister
in interface SubscriptionService<T>
subscriber
- subscriber object being unregisteredpublic void unregister(Action<T> handler)
unregister
in interface SubscriptionService<T>
handler
- the method that performs an action on the specified object
when a publishing event occursprotected void unregisterAll()
protected void notify(T obj)
obj
- object that is used for a publishing event processingprotected void onNotificationException(Subscriber<T> subscriber, java.lang.Exception e)
subscriber
- exception originatore
- thrown exceptionprotected void switchSubscribersList(java.util.List<Subscriber<T>> newList)
newList
- new list
|
Platform SDK Java 8.5 API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |