|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.cache.AbstractNode
org.jboss.cache.Node
public class Node
Field Summary |
---|
Fields inherited from class org.jboss.cache.AbstractNode |
---|
children, data, fqn, INDENT, name, parent |
Fields inherited from interface org.jboss.cache.DataNode |
---|
LOCK_TYPE_NONE, LOCK_TYPE_READ, LOCK_TYPE_WRITE, PRINT_LOCK_DETAILS |
Constructor Summary | |
---|---|
Node()
|
|
Node(java.lang.Object child_name,
Fqn fqn,
Node parent,
java.util.Map data,
boolean mapSafe,
TreeCache cache)
|
|
Node(java.lang.Object child_name,
Fqn fqn,
Node parent,
java.util.Map data,
TreeCache cache)
|
|
Node(java.lang.Object child_name,
Fqn fqn,
Node parent,
java.lang.Object key,
java.lang.Object value,
TreeCache cache)
|
Method Summary | |
---|---|
boolean |
acquire(java.lang.Object caller,
long timeout,
int lock_type)
|
java.util.Set |
acquireAll(java.lang.Object caller,
long timeout,
int lock_type)
Not to be exposed. |
protected boolean |
acquireReadLock(java.lang.Object caller,
long timeout)
|
protected boolean |
acquireWriteLock(java.lang.Object caller,
long timeout)
|
protected java.util.Map |
children()
Override this if concurrent thread access may occur. |
void |
clear()
|
java.lang.Object |
clone()
|
boolean |
containsKey(java.lang.Object key)
|
TreeNode |
createChild(java.lang.Object child_name,
Fqn fqn,
TreeNode parent)
|
TreeNode |
createChild(java.lang.Object child_name,
Fqn fqn,
TreeNode parent,
java.lang.Object key,
java.lang.Object value)
|
java.lang.Object |
get(java.lang.Object key)
|
boolean |
getChildrenLoaded()
Not to be exposed. |
java.util.Map |
getData()
Returns a copy of the attributes. |
java.util.Set |
getDataKeys()
|
IdentityLock |
getImmutableLock()
Deprecated. Use getLock() instead |
IdentityLock |
getLock()
Not to be exposed. |
TreeNode |
getOrCreateChild(java.lang.Object child_name,
GlobalTransaction gtx,
boolean createIfNotExists)
Creates a new child of this node if it doesn't exist. |
TreeNode |
getParent()
|
protected void |
init()
|
protected void |
init(java.lang.Object child_name,
Fqn fqn,
Node parent,
TreeCache cache)
|
boolean |
isLocked()
Not to be exposed. |
int |
numAttributes()
|
void |
printDetails(java.lang.StringBuffer sb,
int indent)
|
void |
printLockInfo(java.lang.StringBuffer sb,
int indent)
Not to be exposed. |
void |
put(java.util.Map data,
boolean erase)
|
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value)
|
void |
readExternal(java.io.ObjectInput in)
|
void |
release(java.lang.Object caller)
Not to be exposed. |
void |
releaseAll(java.lang.Object owner)
Not to be exposed. |
void |
releaseAllForce()
Not to be exposed. |
void |
releaseForce()
Not to be exposed. |
java.lang.Object |
remove(java.lang.Object key)
|
void |
setChildrenLoaded(boolean flag)
Not to be exposed. |
void |
setRecursiveTreeCacheInstance(TreeCache cache)
Set the tree cache instance recursively down to the children as well. |
java.lang.String |
toString()
|
void |
writeExternal(java.io.ObjectOutput out)
|
Methods inherited from class org.jboss.cache.AbstractNode |
---|
addChild, childExists, data, getChild, getChildren, getFqn, getName, hasChildren, print, printDetailsInMap, printIndent, put, removeAllChildren, removeChild, setChildren |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Node()
public Node(java.lang.Object child_name, Fqn fqn, Node parent, java.util.Map data, TreeCache cache)
child_name
- fqn
- parent
- data
- cache
- public Node(java.lang.Object child_name, Fqn fqn, Node parent, java.util.Map data, boolean mapSafe, TreeCache cache)
child_name
- fqn
- parent
- data
- mapSafe
- true
if param data
can safely be
directly assigned to this object's AbstractNode.data
field;
false
if param data
's contents
should be copied into this object's AbstractNode.data
field.cache
- public Node(java.lang.Object child_name, Fqn fqn, Node parent, java.lang.Object key, java.lang.Object value, TreeCache cache)
child_name
- fqn
- parent
- key
- value
- cache
- Method Detail |
---|
protected final void init(java.lang.Object child_name, Fqn fqn, Node parent, TreeCache cache)
public TreeNode getParent()
getParent
in interface TreeNode
getParent
in class AbstractNode
protected void init()
protected java.util.Map children()
AbstractNode
children
in class AbstractNode
public void setRecursiveTreeCacheInstance(TreeCache cache)
setRecursiveTreeCacheInstance
in interface DataNode
setRecursiveTreeCacheInstance
in interface TreeNode
cache
- DataNode
public boolean getChildrenLoaded()
TreeNode
getChildrenLoaded
in interface DataNode
getChildrenLoaded
in interface TreeNode
DataNode
public void setChildrenLoaded(boolean flag)
TreeNode
setChildrenLoaded
in interface DataNode
setChildrenLoaded
in interface TreeNode
DataNode
public java.lang.Object get(java.lang.Object key)
get
in interface TreeNode
public boolean containsKey(java.lang.Object key)
containsKey
in interface TreeNode
DataNode
public java.util.Set getDataKeys()
getDataKeys
in interface TreeNode
DataNode
public boolean isLocked()
TreeNode
isLocked
in interface DataNode
isLocked
in interface TreeNode
DataNode
public IdentityLock getImmutableLock()
TreeNode
getImmutableLock
in interface TreeNode
DataNode
public IdentityLock getLock()
TreeNode
getLock
in interface DataNode
getLock
in interface TreeNode
DataNode
public java.util.Map getData()
TreeNode
getData
in interface DataNode
getData
in interface TreeNode
DataNode
public int numAttributes()
numAttributes
in interface TreeNode
DataNode
public void put(java.util.Map data, boolean erase)
put
in interface TreeNode
public java.lang.Object put(java.lang.Object key, java.lang.Object value)
put
in interface TreeNode
public TreeNode getOrCreateChild(java.lang.Object child_name, GlobalTransaction gtx, boolean createIfNotExists)
DataNode
getOrCreateChild
in interface DataNode
getOrCreateChild
in interface TreeNode
DataNode
public TreeNode createChild(java.lang.Object child_name, Fqn fqn, TreeNode parent)
createChild
in interface TreeNode
public TreeNode createChild(java.lang.Object child_name, Fqn fqn, TreeNode parent, java.lang.Object key, java.lang.Object value)
createChild
in interface TreeNode
DataNode
public java.lang.Object remove(java.lang.Object key)
remove
in interface TreeNode
public void clear()
clear
in interface TreeNode
public void printDetails(java.lang.StringBuffer sb, int indent)
printDetails
in interface DataNode
printDetails
in interface TreeNode
public void printLockInfo(java.lang.StringBuffer sb, int indent)
TreeNode
printLockInfo
in interface DataNode
printLockInfo
in interface TreeNode
DataNode
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in interface DataNode
clone
in class AbstractNode
java.lang.CloneNotSupportedException
public boolean acquire(java.lang.Object caller, long timeout, int lock_type) throws LockingException, TimeoutException, java.lang.InterruptedException
acquire
in interface DataNode
LockingException
TimeoutException
java.lang.InterruptedException
protected boolean acquireReadLock(java.lang.Object caller, long timeout) throws LockingException, TimeoutException, java.lang.InterruptedException
LockingException
TimeoutException
java.lang.InterruptedException
protected boolean acquireWriteLock(java.lang.Object caller, long timeout) throws LockingException, TimeoutException, java.lang.InterruptedException
LockingException
TimeoutException
java.lang.InterruptedException
public java.util.Set acquireAll(java.lang.Object caller, long timeout, int lock_type) throws LockingException, TimeoutException, java.lang.InterruptedException
TreeNode
acquireAll
in interface DataNode
acquireAll
in interface TreeNode
LockingException
TimeoutException
java.lang.InterruptedException
DataNode
public void release(java.lang.Object caller)
TreeNode
release
in interface TreeNode
DataNode
public void releaseForce()
TreeNode
releaseForce
in interface TreeNode
DataNode
public void releaseAll(java.lang.Object owner)
TreeNode
releaseAll
in interface DataNode
releaseAll
in interface TreeNode
DataNode
public void releaseAllForce()
TreeNode
releaseAllForce
in interface DataNode
releaseAllForce
in interface TreeNode
DataNode
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |