|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
@Deprecated public interface WorkspaceNode<K,V>
Represents a type of Node
that is to be copied into a TransactionWorkspace
for optimistically locked
nodes. Adds versioning and dirty flags over conventional Nodes.
Configuration.NodeLockingScheme.OPTIMISTIC
Method Summary | |
---|---|
void |
addChild(WorkspaceNode<K,V> workspaceNode)
Deprecated. Adds a given WorkspaceNode to the current node's child map |
void |
clearData()
Deprecated. |
NodeSPI |
createChild(Object child_name,
NodeSPI<K,V> parent,
CacheSPI<K,V> cache,
DataVersion version)
Deprecated. Creates a child node. |
V |
get(K key)
Deprecated. |
NodeSPI<K,V> |
getChildDirect(Fqn f)
Deprecated. Overrides Node.getChild(Fqn) to return a NodeSPI rather than a Node |
NodeSPI<K,V> |
getChildDirect(Object o)
Deprecated. Overrides Node.getChild(Object) to return a NodeSPI rather than a Node |
Set<Object> |
getChildrenNames()
Deprecated. |
Map<K,V> |
getData()
Deprecated. |
Fqn |
getFqn()
Deprecated. |
Set<K> |
getKeys()
Deprecated. |
List<Set<Fqn>> |
getMergedChildren()
Deprecated. Returns 2 Sets - a set of children added (first set) and a set of children removed. |
Map<K,V> |
getMergedData()
Deprecated. Attempts to merge data changed during the current transaction with the data in the underlying tree. |
NodeSPI<K,V> |
getNode()
Deprecated. Retrieves a reference to the underlying NodeSPI instance. |
TransactionWorkspace |
getTransactionWorkspace()
Deprecated. Retrieves a TransactionWorkspace instance associated with the current transaction, which the current WorkspaceNode instance lives in. |
DataVersion |
getVersion()
Deprecated. Retrieves the data version of the in-memory node. |
boolean |
isChildrenLoaded()
Deprecated. |
boolean |
isChildrenModified()
Deprecated. |
boolean |
isCreated()
Deprecated. |
boolean |
isDirty()
Deprecated. A convenience method that returns whether a node is dirty, i.e., it has been created, deleted or modified. |
boolean |
isModified()
Deprecated. A node is considered modified if its data map has changed. |
boolean |
isRemoved()
Deprecated. |
boolean |
isResurrected()
Deprecated. |
boolean |
isVersioningImplicit()
Deprecated. Tests whether versioning for the WorkspaceNode instance in the current transaction is implicit (i.e., using DefaultDataVersion
rather than a custom DataVersion passed in using Option.setDataVersion(DataVersion) ) |
void |
markAsCreated()
Deprecated. Marks the instance as having been created in the current transaction. |
void |
markAsRemoved(boolean marker,
boolean recursive)
Deprecated. |
void |
markAsResurrected(boolean resurrected)
Deprecated. Marks a node as resurrected, i.e., deleted and created again within the same transaction |
V |
put(K key,
V value)
Deprecated. |
void |
putAll(Map<K,V> data)
Deprecated. |
V |
remove(K removeKey)
Deprecated. |
boolean |
removeChild(Object nodeName)
Deprecated. |
void |
setRemoved(boolean marker)
Deprecated. |
void |
setVersion(DataVersion version)
Deprecated. Sets the data version of this workspace node. |
void |
setVersioningImplicit(boolean b)
Deprecated. Sets whether versioning for the WorkspaceNode instance in the current transaction is implicit (i.e., using DefaultDataVersion
rather than a custom DataVersion passed in using Option.setDataVersion(DataVersion) ) |
Method Detail |
---|
Fqn getFqn()
List<Set<Fqn>> getMergedChildren()
DataVersion getVersion()
void setVersion(DataVersion version)
version
- a DataVersion
implementation.boolean isModified()
isChildrenModified()
.
boolean isDirty()
isChildrenModified()
Map<K,V> getMergedData()
NodeSPI<K,V> getNode()
NodeSPI
instance.
TransactionWorkspace getTransactionWorkspace()
boolean isCreated()
void markAsCreated()
NodeSPI createChild(Object child_name, NodeSPI<K,V> parent, CacheSPI<K,V> cache, DataVersion version)
child_name
- Object name of the child to createparent
- A reference to the parent nodecache
- CacheSPI instance to create this node inversion
- DataVersion to apply to the child. If null, DefaultDataVersion.ZERO
will be used.
boolean isVersioningImplicit()
DefaultDataVersion
rather than a custom DataVersion
passed in using Option.setDataVersion(DataVersion)
)
void setVersioningImplicit(boolean b)
DefaultDataVersion
rather than a custom DataVersion
passed in using Option.setDataVersion(DataVersion)
)
b
- set to true if versioning is implicit, false otherwise.NodeSPI<K,V> getChildDirect(Object o)
Node.getChild(Object)
to return a NodeSPI
rather than a Node
o
- node name
NodeSPI<K,V> getChildDirect(Fqn f)
Node.getChild(Fqn)
to return a NodeSPI
rather than a Node
f
- node fqn
void addChild(WorkspaceNode<K,V> workspaceNode)
workspaceNode
- boolean isChildrenModified()
boolean isChildrenLoaded()
boolean isResurrected()
void markAsResurrected(boolean resurrected)
resurrected
- boolean isRemoved()
void setRemoved(boolean marker)
void markAsRemoved(boolean marker, boolean recursive)
void clearData()
Map<K,V> getData()
V remove(K removeKey)
V get(K key)
Set<K> getKeys()
Set<Object> getChildrenNames()
boolean removeChild(Object nodeName)
void putAll(Map<K,V> data)
V put(K key, V value)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |