Interface IWatcher
- All Known Implementing Classes:
AgentWatcher
,GenericWatcher
,NewClassInstanceWatcher
public interface IWatcher
Interface to patterns that may trigger events.
A class which implements IWatcher is expected to represent an "event trigger
pattern" for the ontology. A watcher has a event type
and a watch pattern. See IWatcher.EventType
for details regarding
how the pattern should look like according to the event type.
When the event is triggered, its #notifySubscriber(OroEvent)
method
is called and expected to warn the event subscribers that the event they were
watching occurred.
The way the trigger is actually fired depends on the triggering mode, as
returned by getTriggeringType()
. Supported trigger mode are defined
in IWatcher.TriggeringType
.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enum
Constants that defines the type of event the event module can handle.static enum
Constants that defines the way an event is triggered. -
Method Summary
Modifier and TypeMethodDescriptionvoid
boolean
getId()
Returns a unique (at least for this instance of the server) identifier for the current event watcher.void
-
Method Details
-
getWatchPattern
-
getPatternType
IWatcher.EventType getPatternType() -
getTriggeringType
IWatcher.TriggeringType getTriggeringType() -
notifySubscribers
-
addSubscriber
-
getId
UUID getId()Returns a unique (at least for this instance of the server) identifier for the current event watcher.- Returns:
- A unique ID associated to this event watcher.
-
equals
-