|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object sofya.ed.semantic.EventFilter
public abstract class EventFilter
Abstract base class for all classes that wish to filter observable events
in some way. It is intended that these filters can be registered with
the SemanticEventTracer
as well as chained together to
filter and extract relevant events from the event stream online.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface sofya.ed.semantic.EventListener |
---|
EventListener.Arguments, EventListener.CallData, EventListener.ExceptionData, EventListener.FieldData, EventListener.MethodData, EventListener.MonitorData, EventListener.NewAllocationData, EventListener.ObjectData, EventListener.ThreadData, EventListener.ThreadStatus |
Field Summary | |
---|---|
protected int |
listenerCount
Number of listeners currently registered. |
protected EventListener[] |
listeners
Registered event listeners. |
Constructor Summary | |
---|---|
EventFilter()
|
Method Summary | |
---|---|
void |
addEventListener(EventListener listener)
Registers a listener for observable events. |
protected void |
ensureCapacity(int index)
Ensures that the array of listeners will be large enough to store a listener at a given index. |
void |
removeEventListener(EventListener listener)
Unregisters a listener for observable events. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected EventListener[] listeners
protected int listenerCount
Constructor Detail |
---|
public EventFilter()
Method Detail |
---|
public void addEventListener(EventListener listener)
listener
- Object which wishes to receive notifications of
events related to observables in the system.public void removeEventListener(EventListener listener)
listener
- Object which no longer wishes to receive notifications
of events related to observables in the system.protected void ensureCapacity(int index)
index
- Index which must be within the bounds of the array of
listeners. If the array is not currently of sufficient size for the
given index to be legal, the array will be extended such that it is.
Otherwise this method does nothing. Negative values will be ignored.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |