public class UpdateEventPublisherImpl extends Object implements UpdateEventPublisher
UpdateEventPublisher.| Modifier and Type | Class and Description |
|---|---|
protected class |
UpdateEventPublisherImpl.Subscription
A Subscription keeps track of the event types an
UpdateEventSubscriber
is interested in. |
| Constructor and Description |
|---|
UpdateEventPublisherImpl()
Construct an
UpdateEventPublisher. |
| Modifier and Type | Method and Description |
|---|---|
int |
clear()
Forget all events collected without notifying subscribers.
|
void |
publish(UpdateEvent event,
boolean immediate)
Publish an event.
|
void |
release()
Release deferred events.
|
void |
subscribe(UpdateEventSubscriber subscriber,
DBObjectType type,
boolean priority)
Add a subscriber to event for a given database object type.
|
void |
unsubscribe(UpdateEventSubscriber subscriber)
Remove a subscriber.
|
void |
unsubscribeAll()
Remove all subscribers.
|
public UpdateEventPublisherImpl()
UpdateEventPublisher.public void subscribe(UpdateEventSubscriber subscriber, DBObjectType type, boolean priority)
UpdateEventPublishersubscribe in interface UpdateEventPublishersubscriber - an update event subscribertype - the database object type subscribed topriority - if true, handle as a priority subscriptionpublic void unsubscribe(UpdateEventSubscriber subscriber)
UpdateEventPublisherunsubscribe in interface UpdateEventPublishersubscriber - an update event subscriberpublic void unsubscribeAll()
UpdateEventPublisherunsubscribeAll in interface UpdateEventPublisherpublic void publish(UpdateEvent event, boolean immediate)
UpdateEventPublisherUpdateEventPublisher.release() method is invoked.publish in interface UpdateEventPublisherevent - an update eventimmediate - if true notify subscribers immediatelypublic void release()
UpdateEventPublisherrelease in interface UpdateEventPublisherpublic int clear()
Copyright © 2017. All rights reserved.