|
Plexus v0.13.1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.phoenixst.plexus.util.ForwardingGraphListener
com.phoenixst.plexus.util.FilteredGraphListener
public class FilteredGraphListener
A GraphListener which filters events to be forwarded
to an ObservableGraphDelegate. Instances of this class
only keep a WeakReference to their delegates. If
that Reference has been cleared when an event is received, this
listener will remove itself as a listener of the
Graph which sent the event. Because of this, it is
necessary for the Graph which is using this listener
to maintain a strong reference to the
ObservableGraphDelegate.
| Constructor Summary | |
|---|---|
FilteredGraphListener(org.apache.commons.collections.Predicate nodePredicate,
org.apache.commons.collections.Predicate edgePredicate,
ObservableGraphDelegate observableDelegate)
|
|
| Method Summary | |
|---|---|
void |
edgeAdded(GraphEvent event)
Invoked when an edge has been added to the Graph. |
void |
edgeRemoved(GraphEvent event)
Invoked when an edge has been removed from the Graph. |
void |
nodeAdded(GraphEvent event)
Invoked when a node has been added to the Graph. |
void |
nodeRemoved(GraphEvent event)
Invoked when a node has been removed from the Graph. |
| Methods inherited from class com.phoenixst.plexus.util.ForwardingGraphListener |
|---|
checkDelegate, fireEdgeAdded, fireEdgeRemoved, fireNodeAdded, fireNodeRemoved |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FilteredGraphListener(org.apache.commons.collections.Predicate nodePredicate,
org.apache.commons.collections.Predicate edgePredicate,
ObservableGraphDelegate observableDelegate)
| Method Detail |
|---|
public void nodeAdded(GraphEvent event)
GraphListenerGraph.
nodeAdded in interface GraphListenernodeAdded in class ForwardingGraphListenerpublic void nodeRemoved(GraphEvent event)
GraphListenerGraph.
nodeRemoved in interface GraphListenernodeRemoved in class ForwardingGraphListenerpublic void edgeAdded(GraphEvent event)
GraphListenerGraph.
edgeAdded in interface GraphListeneredgeAdded in class ForwardingGraphListenerpublic void edgeRemoved(GraphEvent event)
GraphListenerGraph.
edgeRemoved in interface GraphListeneredgeRemoved in class ForwardingGraphListener
|
Plexus v0.13.1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||