|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectist.palcom.hmap.HmapNode
ist.palcom.hmap.HmapDir
public class HmapDir
| Nested Class Summary | |
|---|---|
class |
HmapDir.EntryHandler
|
| Nested classes/interfaces inherited from class ist.palcom.hmap.HmapNode |
|---|
HmapNode.NameHandler |
| Field Summary | |
|---|---|
protected Collection |
entries
Collection of entries contained by this h-map dir. |
static String |
HMAPDIR_COMMAND_ADDNODE
|
static String |
HMAPDIR_COMMAND_REMOVENODE
|
| Fields inherited from class ist.palcom.hmap.HmapNode |
|---|
HET_DIR, HET_LEAF, HET_UNKNOWN, HMAPNODE_COMMAND_GETNAME, HMAPNODE_COMMAND_SETNAME, nameInvokator, nodeInvokator, parent, path, valueInvokator |
| Constructor Summary | |
|---|---|
|
HmapDir()
|
|
HmapDir(String name)
|
protected |
HmapDir(String name,
String typeName,
String typeVersion,
String typeFullyQualifiedVersion)
|
| Method Summary | |
|---|---|
protected void |
_addNode(HmapNode node)
|
void |
addNode(HmapEvent event)
Adds a hmap node to this dir Ensures that the child name is unique |
void |
addNode(HmapNode node)
Adds a hmap node to this dir Ensures that the child name is unique |
protected void |
invokeHandlers(HmapEvent event)
Relays the invocation of a handler in accordance with its destination given in the event |
protected void |
invokeHandlersDown(HmapEvent event)
Invokes a handler on a downwards path. |
protected void |
invokeHandlersUp(HmapEvent event,
int commonPoint)
Invokes a handler on an upwards path with background in a precalculated common point |
protected boolean |
isAncestorOf(HmapNode node)
Returns true if this node is a direct ancestor of |
Iterator |
iterator()
|
protected void |
recalculatePath(HmapPath parentPath)
Recalculates the path on the basis of the path of ones ancestors |
void |
removeNode(HmapEvent event)
|
void |
removeNode(HmapNode node)
Removes a node from this dir |
boolean |
removeNode(String name)
Removes the first found child node of this dir named |
HmapNode |
resolve(HmapPath resolvePath,
int type)
Resolves the node a the given path |
HmapNode |
resolveLocally(HmapKey key,
int type)
Resolves a child of the current node |
String |
toString()
|
String |
toString(int indent)
|
String |
toStringAll(int indent)
|
String |
toStringFlat()
|
| Methods inherited from class ist.palcom.hmap.HmapNode |
|---|
addHandler, addInvokator, addListener, asDir, asLeaf, callback, getFullyQualifiedType, getHmapEntryType, getKey, getName, getParent, getPath, getType, getTypeVersion, handle, handlerIterator, hasHandlers, hasInvokators, hasListeners, hasName, hasType, invokation, invokatorIterator, invokeListeners, isDir, isLeaf, listenerIterator, printHandlers, printInvokators, printListeners, recalculatePath, removeHandler, removeInvocator, removeListener, resolve, resolve, resolveDir, resolveDir, resolveDirLocally, resolveDirLocally, resolveLeaf, resolveLeaf, resolveLeafLocally, resolveLeafLocally, resolveLocally, resolveLocally, setName, setName, setParent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, println |
| Field Detail |
|---|
public static final String HMAPDIR_COMMAND_ADDNODE
public static final String HMAPDIR_COMMAND_REMOVENODE
protected Collection entries
| Constructor Detail |
|---|
public HmapDir()
public HmapDir(String name)
name - The name of the directory
protected HmapDir(String name,
String typeName,
String typeVersion,
String typeFullyQualifiedVersion)
| Method Detail |
|---|
public HmapNode resolveLocally(HmapKey key,
int type)
HmapNode
resolveLocally in class HmapNodekey - The key of the childtype - The type of the given node. Can be leaf, dir and unknown
public HmapNode resolve(HmapPath resolvePath,
int type)
resolve in class HmapNoderesolvePath - the path of the node to resolvetype - the type of the given node. Can be leaf, dir and unknown
protected void invokeHandlers(HmapEvent event)
invokeHandlers in class HmapNodeevent - The event to invoke the handlers with
protected void invokeHandlersUp(HmapEvent event,
int commonPoint)
event - The HmapEventcommonPoint - The precalculated common point between the current path and the path to be resolvedprotected void invokeHandlersDown(HmapEvent event)
event - The HmapEventpublic void addNode(HmapNode node)
node - The node to addpublic void addNode(HmapEvent event)
event - The event containing node to addprotected void _addNode(HmapNode node)
protected boolean isAncestorOf(HmapNode node)
HmapNode
isAncestorOf in class HmapNodenode - The potential (grand)child node
public void removeNode(HmapNode node)
node - The entry to removepublic void removeNode(HmapEvent event)
public boolean removeNode(String name)
name - The name of the child node to remove
public Iterator iterator()
protected void recalculatePath(HmapPath parentPath)
HmapNode
recalculatePath in class HmapNodeparentPath - The path of ones parentpublic String toString()
toString in class Objectpublic String toStringFlat()
public String toString(int indent)
toString in class HmapNodeindent - Start the returned string with a number of whitespaces
public String toStringAll(int indent)
toStringAll in class HmapNodeindent - prepend a number of whitespaces to the retured string
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||