Package org.terracotta.context
Class MutableTreeNode
- java.lang.Object
-
- org.terracotta.context.AbstractTreeNode
-
- org.terracotta.context.MutableTreeNode
-
- All Implemented Interfaces:
TreeNode,WeakIdentityHashMap.Cleanable
class MutableTreeNode extends AbstractTreeNode
-
-
Field Summary
Fields Modifier and Type Field Description private ContextElementcontextprivate java.util.concurrent.CopyOnWriteArraySet<AbstractTreeNode>parents
-
Constructor Summary
Constructors Constructor Description MutableTreeNode(ContextElement context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) voidaddedParent(AbstractTreeNode parent)(package private) java.util.Set<AbstractTreeNode>getAncestors()ContextElementgetContext()Returns the context information associated with this node.java.util.Collection<ContextListener>getListeners()java.util.Collection<java.util.List<? extends TreeNode>>getPaths()Returns the complete set of rooting paths for this context element.(package private) voidremovedParent(AbstractTreeNode parent)java.lang.StringtoString()-
Methods inherited from class org.terracotta.context.AbstractTreeNode
addChild, clean, dumpSubtree, getChildren, getPath, removeChild, toTreeString
-
-
-
-
Field Detail
-
parents
private final java.util.concurrent.CopyOnWriteArraySet<AbstractTreeNode> parents
-
context
private final ContextElement context
-
-
Constructor Detail
-
MutableTreeNode
public MutableTreeNode(ContextElement context)
-
-
Method Detail
-
getContext
public ContextElement getContext()
Description copied from interface:TreeNodeReturns the context information associated with this node.- Returns:
- node context information
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getAncestors
java.util.Set<AbstractTreeNode> getAncestors()
- Specified by:
getAncestorsin classAbstractTreeNode
-
getListeners
public java.util.Collection<ContextListener> getListeners()
- Specified by:
getListenersin classAbstractTreeNode
-
addedParent
void addedParent(AbstractTreeNode parent)
- Specified by:
addedParentin classAbstractTreeNode
-
removedParent
void removedParent(AbstractTreeNode parent)
- Specified by:
removedParentin classAbstractTreeNode
-
-