| 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--ostore.dispatch.TrieNode
A node of a trie for use with a Classifier object.
 
 A TrieNode stores the SinkIFs associated with
 the Filter defined by the path from the root of the trie.  It
 also stores enough information about its children to recursively classify
 QueueElementIFs.  Information about the requirement represented by
 this TrieNode is stored on the edge to this node from its
 parent, not internally to this data structure.
| Field Summary | |
|---|---|
protected  Vector | 
fields
Contains the set of Fields checked by this node's
 children. | 
protected  Vector | 
priorities
Contains the priorities for the SinkIFs.   | 
protected  Vector | 
rates
Contains the pass rates for the SinkIFs.   | 
protected  Vector | 
sinks
Contains all of the SinkIFs to receive events which
 satisfy this node's requirement. | 
protected  Vector | 
value_maps
Contains the set of value->child mappings for each Field.
  | 
| Constructor Summary | |
|---|---|
protected  | 
TrieNode()
Creates a new TrieNode with no sinks or children. | 
| Method Summary | |
|---|---|
 void | 
addChild(TrieNode child,
         Field field,
         Object value)
Add a child node with a specified field-value restriction.  | 
 void | 
addSink(SinkIF sink,
        Integer priority,
        double acceptance_rate)
Add a new SinkIF to receive for all
 QueueElementIF satisfying this node in the trie. | 
 Object | 
clone()
Performs a deeper copy than Object.clone would.
  | 
 void | 
collectSinks(QueueElementIF event,
             HashMap found)
Recursively find all TrieNodes which pass the specified
 event, collecting all the SinkIFs subscribed at each node. | 
 String | 
toString()
 | 
| Methods inherited from class java.lang.Object | 
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
protected Vector sinks
SinkIFs to receive events which
 satisfy this node's requirement.
protected Vector priorities
SinkIFs.  This
 Vector is parallel to sinks.
protected Vector rates
SinkIFs.  This
 Vector is parallel to sinks.
protected Vector fields
Fields checked by this node's
 children.
protected Vector value_maps
Field.
 This Vector is parallel to fields.
| Constructor Detail | 
protected TrieNode()
TrieNode with no sinks or children.
| Method Detail | 
public void collectSinks(QueueElementIF event,
                         HashMap found)
TrieNodes which pass the specified
 event, collecting all the SinkIFs subscribed at each node.
event - The QueueElementIF to evaluate.found - The set of SinkIFs collected. Each
 			SinkIF maps to its priority.
public void addChild(TrieNode child,
                     Field field,
                     Object value)
QueueElementIF which satisfies this node's restriction
 should test the new child's as well.
child - The node to add.field - The Field restricted by the child.value - The value that Field should have.
public void addSink(SinkIF sink,
                    Integer priority,
                    double acceptance_rate)
SinkIF to receive for all
 QueueElementIF satisfying this node in the trie.
sink - the SinkIF.priority - a number between 0 (lowest priority) and 10 (highest).acceptance_rate - the fraction of qualifying events to pass on
 			to the sink.  Useful for sampling the input stream.public Object clone()
Object.clone would.
 The entire trie is cloned, and may be modified independently of the
 original.  The Fields and SinkIFs
 referenced by the TrieNodes are not cloned.
clone in class ObjectTrieNode with cloned
 internal data structures.public String toString()
toString in class Object
  | 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||