|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.cache.optimistic.WorkspaceNodeImpl
public class WorkspaceNodeImpl
Wraps a DataNode and adds versioning and other meta data to it.
Constructor Summary | |
---|---|
WorkspaceNodeImpl()
|
|
WorkspaceNodeImpl(DataNode node,
TransactionWorkspace workspace)
Constructs with a node and workspace. |
|
WorkspaceNodeImpl(TreeNode node,
TransactionWorkspace workspace)
Deprecated. |
Method Summary | |
---|---|
java.util.Set |
acquireAll(java.lang.Object caller,
long timeout,
int lock_type)
Deprecated. Will be removed in JBossCache 1.3. |
void |
addChild(java.lang.Object child_name,
TreeNode n)
Deprecated. Will be removed in JBossCache 1.3. |
boolean |
childExists(java.lang.Object child_name)
Deprecated. Will be removed in JBossCache 1.3. |
void |
clear()
Clears the data of this node. |
boolean |
containsKey(java.lang.Object key)
Deprecated. Will be removed in JBossCache 1.3. |
TreeNode |
createChild(java.lang.Object child_name,
Fqn fqn,
TreeNode parent)
Creates a child node with a name, FQN, and parent. |
TreeNode |
createChild(java.lang.Object child_name,
Fqn fqn,
TreeNode parent,
java.lang.Object key,
java.lang.Object value)
Deprecated. Will be removed in JBossCache 1.3. |
TreeNode |
createChild(java.lang.Object child_name,
Fqn fqn,
TreeNode parent,
TreeCache cache,
DataVersion version)
|
java.lang.Object |
get(java.lang.Object key)
Returns the value of a key or null if it does not exist. |
TreeNode |
getChild(java.lang.Object childName)
Returns the named child of this node. |
java.util.Map |
getChildren()
Always returns null; dummy method for TreeNode compatibility. |
boolean |
getChildrenLoaded()
Deprecated. Will be removed in JBossCache 1.3. |
java.util.Set |
getChildrenNames()
|
java.util.Map |
getData()
Always returns null; dummy method for TreeNode compatibility. |
java.util.Set |
getDataKeys()
Deprecated. Will be removed in JBossCache 1.3. |
Fqn |
getFqn()
Returns the fully qualified name of the node. |
IdentityLock |
getImmutableLock()
Deprecated. Will be removed in JBossCache 1.3. |
java.util.Set |
getKeys()
|
IdentityLock |
getLock()
Deprecated. Will be removed in JBossCache 1.3. |
java.util.Map |
getMergedChildren()
|
java.util.Map |
getMergedData()
|
java.lang.Object |
getName()
Returns the name of this node. |
DataNode |
getNode()
|
TreeNode |
getOrCreateChild(java.lang.Object child_name,
GlobalTransaction gtx,
boolean createIfNotExists)
Deprecated. Will be removed in JBossCache 1.3. |
TreeNode |
getParent()
Returns the parent of this node. |
TransactionWorkspace |
getTransactionWorkspace()
|
DataVersion |
getVersion()
|
TreeNode |
getWrappedChild(java.lang.Object fqn)
|
TreeNode |
getWrappedParent()
|
boolean |
hasChildren()
Deprecated. Will be removed in JBossCache 1.3. |
boolean |
isCreated()
|
boolean |
isDeleted()
|
boolean |
isDirty()
Returns true if this node is dirty. |
boolean |
isLocked()
Deprecated. Will be removed in JBossCache 1.3. |
void |
markAsCreated()
|
void |
markAsDeleted()
|
int |
numAttributes()
Deprecated. Will be removed in JBossCache 1.3. |
void |
print(java.lang.StringBuffer sb,
int indent)
Deprecated. Will be removed in JBossCache 1.3. |
void |
printDetails(java.lang.StringBuffer sb,
int indent)
Deprecated. Will be removed in JBossCache 1.3. |
void |
printIndent(java.lang.StringBuffer sb,
int indent)
Deprecated. Will be removed in JBossCache 1.3. |
void |
printLockInfo(java.lang.StringBuffer sb,
int indent)
Deprecated. Will be removed in JBossCache 1.3. |
void |
put(java.util.Map data)
Adds (merges) the contents of the map with the existing data. |
void |
put(java.util.Map data,
boolean eraseData)
Puts the contents of a map into this node. |
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value)
Puts the key and value into the node. |
void |
release(java.lang.Object caller)
Deprecated. Will be removed in JBossCache 1.3. |
void |
releaseAll(java.lang.Object owner)
Deprecated. Will be removed in JBossCache 1.3. |
void |
releaseAllForce()
Deprecated. Will be removed in JBossCache 1.3. |
void |
releaseForce()
Deprecated. Will be removed in JBossCache 1.3. |
java.lang.Object |
remove(java.lang.Object key)
Removes the old value of the key. |
void |
removeAllChildren()
Deprecated. Will be removed in JBossCache 1.3. |
void |
removeChild(java.lang.Object childName)
Removes the named child of this node. |
void |
setChildren(java.util.Map children)
Deprecated. Will be removed in JBossCache 1.3. |
void |
setChildrenLoaded(boolean b)
Deprecated. Will be removed in JBossCache 1.3. |
void |
setRecursiveTreeCacheInstance(TreeCache cache)
Deprecated. Will be removed in JBossCache 1.3. |
void |
setVersion(DataVersion version)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public WorkspaceNodeImpl()
public WorkspaceNodeImpl(TreeNode node, TransactionWorkspace workspace)
public WorkspaceNodeImpl(DataNode node, TransactionWorkspace workspace)
Method Detail |
---|
public boolean isDirty()
isDirty
in interface WorkspaceNode
public Fqn getFqn()
TreeNode
getFqn
in interface TreeNode
public void put(java.util.Map data, boolean eraseData)
TreeNode
put
in interface TreeNode
eraseData
- true to erase the existing contentspublic void put(java.util.Map data)
TreeNode
put
in interface TreeNode
public java.lang.Object put(java.lang.Object key, java.lang.Object value)
TreeNode
put
in interface TreeNode
public java.lang.Object remove(java.lang.Object key)
TreeNode
remove
in interface TreeNode
public void clear()
TreeNode
clear
in interface TreeNode
public java.lang.Object get(java.lang.Object key)
TreeNode
get
in interface TreeNode
public java.util.Set getKeys()
getKeys
in interface WorkspaceNode
public java.util.Set getChildrenNames()
getChildrenNames
in interface WorkspaceNode
public void removeChild(java.lang.Object childName)
TreeNode
removeChild
in interface TreeNode
public TreeNode getParent()
TreeNode
getParent
in interface TreeNode
public TreeNode getWrappedParent()
public TreeNode createChild(java.lang.Object child_name, Fqn fqn, TreeNode parent)
TreeNode
createChild
in interface TreeNode
public TreeNode createChild(java.lang.Object child_name, Fqn fqn, TreeNode parent, TreeCache cache, DataVersion version)
createChild
in interface WorkspaceNode
public TreeNode getChild(java.lang.Object childName)
TreeNode
getChild
in interface TreeNode
public TreeNode getWrappedChild(java.lang.Object fqn)
public DataNode getNode()
getNode
in interface WorkspaceNode
public DataVersion getVersion()
getVersion
in interface WorkspaceNode
public void setVersion(DataVersion version)
setVersion
in interface WorkspaceNode
public java.util.Map getMergedChildren()
getMergedChildren
in interface WorkspaceNode
public java.util.Map getMergedData()
getMergedData
in interface WorkspaceNode
public void markAsDeleted()
markAsDeleted
in interface WorkspaceNode
public boolean isDeleted()
isDeleted
in interface WorkspaceNode
public java.lang.Object getName()
TreeNode
getName
in interface TreeNode
public TransactionWorkspace getTransactionWorkspace()
getTransactionWorkspace
in interface WorkspaceNode
public boolean isCreated()
isCreated
in interface WorkspaceNode
public void markAsCreated()
markAsCreated
in interface WorkspaceNode
public java.util.Map getData()
getData
in interface TreeNode
DataNode
public java.util.Map getChildren()
getChildren
in interface TreeNode
public boolean containsKey(java.lang.Object key)
TreeNode
containsKey
in interface TreeNode
DataNode
public java.util.Set getDataKeys()
TreeNode
getDataKeys
in interface TreeNode
DataNode
public boolean childExists(java.lang.Object child_name)
TreeNode
childExists
in interface TreeNode
DataNode
public IdentityLock getImmutableLock()
TreeNode
getImmutableLock
in interface TreeNode
DataNode
public IdentityLock getLock()
TreeNode
getLock
in interface TreeNode
DataNode
public int numAttributes()
TreeNode
numAttributes
in interface TreeNode
DataNode
public boolean hasChildren()
TreeNode
hasChildren
in interface TreeNode
DataNode
public TreeNode getOrCreateChild(java.lang.Object child_name, GlobalTransaction gtx, boolean createIfNotExists)
getOrCreateChild
in interface TreeNode
DataNode
public TreeNode createChild(java.lang.Object child_name, Fqn fqn, TreeNode parent, java.lang.Object key, java.lang.Object value)
TreeNode
createChild
in interface TreeNode
DataNode
public void removeAllChildren()
TreeNode
removeAllChildren
in interface TreeNode
DataNode
public void print(java.lang.StringBuffer sb, int indent)
TreeNode
print
in interface TreeNode
DataNode
public void printDetails(java.lang.StringBuffer sb, int indent)
TreeNode
printDetails
in interface TreeNode
DataNode
public void printIndent(java.lang.StringBuffer sb, int indent)
TreeNode
printIndent
in interface TreeNode
DataNode
public void addChild(java.lang.Object child_name, TreeNode n)
addChild
in interface TreeNode
DataNode
public void printLockInfo(java.lang.StringBuffer sb, int indent)
TreeNode
printLockInfo
in interface TreeNode
DataNode
public boolean isLocked()
TreeNode
isLocked
in interface TreeNode
DataNode
public void releaseAll(java.lang.Object owner)
TreeNode
releaseAll
in interface TreeNode
DataNode
public void releaseAllForce()
TreeNode
releaseAllForce
in interface TreeNode
DataNode
public java.util.Set acquireAll(java.lang.Object caller, long timeout, int lock_type) throws LockingException, TimeoutException, java.lang.InterruptedException
TreeNode
acquireAll
in interface TreeNode
LockingException
TimeoutException
java.lang.InterruptedException
DataNode
public void setRecursiveTreeCacheInstance(TreeCache cache)
TreeNode
setRecursiveTreeCacheInstance
in interface TreeNode
DataNode
public boolean getChildrenLoaded()
TreeNode
getChildrenLoaded
in interface TreeNode
DataNode
public void setChildrenLoaded(boolean b)
TreeNode
setChildrenLoaded
in interface TreeNode
DataNode
public void setChildren(java.util.Map children)
public void release(java.lang.Object caller)
TreeNode
release
in interface TreeNode
DataNode
public void releaseForce()
TreeNode
releaseForce
in interface TreeNode
DataNode
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |