|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.cache.AbstractNode<K,V> org.jboss.cache.UnversionedNode<K,V>
public class UnversionedNode<K,V>
Basic data node class. Throws UnsupportedOperationException
for version-specific methods like getVersion()
and
setVersion(org.jboss.cache.optimistic.DataVersion)
, defined in NodeSPI
.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.jboss.cache.AbstractNode |
---|
AbstractNode.NodeFlags |
Field Summary | |
---|---|
protected NodeSPI |
delegate
|
protected IdentityLock |
lock
Lock manager that manages locks to be acquired when accessing the node inside a transaction. |
protected LockStrategyFactory |
lockStrategyFactory
|
protected static org.apache.commons.logging.Log |
log
Debug log. |
protected static boolean |
trace
|
Fields inherited from class org.jboss.cache.AbstractNode |
---|
children, flags, fqn |
Constructor Summary | |
---|---|
|
UnversionedNode()
Constructs a new node with an FQN of Root. |
protected |
UnversionedNode(Object child_name,
Fqn fqn,
Map data,
boolean mapSafe,
CacheSPI cache)
Constructs a new node with a name, etc. |
Method Summary | |
---|---|
void |
addChild(Object child_name,
Node n)
|
NodeSPI |
addChildDirect(Fqn f)
|
NodeSPI |
addChildDirect(Fqn f,
boolean notify)
|
void |
addChildDirect(NodeSPI child)
|
NodeSPI |
addChildDirect(Object childName,
boolean notify)
|
void |
clearDataDirect()
|
Object |
get(Object key)
|
CacheSPI |
getCache()
|
NodeSPI |
getChildDirect(Fqn fqn)
|
NodeSPI |
getChildDirect(Object childName)
|
Set<NodeSPI> |
getChildrenDirect()
|
Set<NodeSPI> |
getChildrenDirect(boolean includeMarkedForRemoval)
|
Map<Object,Node<K,V>> |
getChildrenMapDirect()
|
Set<Object> |
getChildrenNamesDirect()
|
Map |
getDataDirect()
|
NodeSPI |
getDelegate()
|
Object |
getDirect(Object key)
|
Fqn |
getFqn()
Returns the name of this node. |
Map |
getInternalState(boolean onlyInternalState)
|
Set<Object> |
getKeysDirect()
|
IdentityLock |
getLock()
|
NodeSPI |
getOrCreateChild(Object child_name,
GlobalTransaction gtx,
boolean notify)
|
NodeSPI |
getParent()
Returns a parent by checking the TreeMap by name. |
DataVersion |
getVersion()
|
boolean |
hasChildrenDirect()
|
protected void |
initFlags()
This method initialises flags on the node, by setting DATA_LOADED to true and VALID to true and all other flags to false. |
protected void |
initLock()
|
void |
injectDependencies(CacheSPI spi,
CommandsFactory commandsFactory,
LockStrategyFactory lockStrategyFactory)
|
boolean |
isChildrenLoaded()
|
boolean |
isDataLoaded()
Returns true if the data was loaded from the cache loader. |
boolean |
isLockForChildInsertRemove()
|
boolean |
isValid()
|
void |
printDetails(StringBuilder sb,
int indent)
|
Object |
put(Object key,
Object value)
|
void |
putAll(Map data)
|
void |
putAllDirect(Map data)
|
Object |
putDirect(Object key,
Object value)
|
void |
releaseObjectReferences(boolean recursive)
|
Object |
remove(Object key)
|
boolean |
removeChildDirect(Fqn f)
|
boolean |
removeChildDirect(Object childName)
|
void |
removeChildrenDirect()
|
Object |
removeDirect(Object key)
|
void |
setChildrenLoaded(boolean childrenLoaded)
|
void |
setChildrenMapDirect(Map<Object,Node<K,V>> children)
|
void |
setDataLoaded(boolean dataLoaded)
Sets if the data was loaded from the cache loader. |
void |
setDelegate(NodeSPI delegate)
|
void |
setFqn(Fqn fqn)
|
void |
setInternalState(Map state)
|
void |
setLockForChildInsertRemove(boolean lockForChildInsertRemove)
|
void |
setValid(boolean valid,
boolean recursive)
|
void |
setVersion(DataVersion version)
|
String |
toString()
Returns a debug string. |
Methods inherited from class org.jboss.cache.AbstractNode |
---|
equals, hashCode, isDeleted, isFlagSet, isResident, markAsDeleted, markAsDeleted, setFlag, setFlag, setResident, unsetFlag |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static org.apache.commons.logging.Log log
protected static final boolean trace
protected transient IdentityLock lock
protected NodeSPI delegate
protected LockStrategyFactory lockStrategyFactory
Constructor Detail |
---|
public UnversionedNode()
protected UnversionedNode(Object child_name, Fqn fqn, Map data, boolean mapSafe, CacheSPI cache)
mapSafe
- true
if param data
can safely be directly assigned to this object's
data
field; false
if param data
's contents should be copied into
this object's data
field.Method Detail |
---|
protected void initFlags()
NodeFlags
enum.
public NodeSPI getDelegate()
public void setDelegate(NodeSPI delegate)
public void injectDependencies(CacheSPI spi, CommandsFactory commandsFactory, LockStrategyFactory lockStrategyFactory)
public NodeSPI getParent()
protected void initLock()
public CacheSPI getCache()
public boolean isChildrenLoaded()
public void setChildrenLoaded(boolean childrenLoaded)
public Object get(Object key)
public Object getDirect(Object key)
public IdentityLock getLock()
public Map getDataDirect()
public Object put(Object key, Object value)
public Object putDirect(Object key, Object value)
public NodeSPI getOrCreateChild(Object child_name, GlobalTransaction gtx, boolean notify)
public Object remove(Object key)
public Object removeDirect(Object key)
public void printDetails(StringBuilder sb, int indent)
public String toString()
toString
in class Object
public void addChildDirect(NodeSPI child)
public NodeSPI addChildDirect(Fqn f)
public NodeSPI addChildDirect(Fqn f, boolean notify)
public NodeSPI addChildDirect(Object childName, boolean notify)
public void clearDataDirect()
public NodeSPI getChildDirect(Fqn fqn)
public Set<Object> getChildrenNamesDirect()
public Set<Object> getKeysDirect()
public boolean removeChildDirect(Object childName)
public boolean removeChildDirect(Fqn f)
public Map<Object,Node<K,V>> getChildrenMapDirect()
public void setChildrenMapDirect(Map<Object,Node<K,V>> children)
public void putAll(Map data)
public void putAllDirect(Map data)
public void removeChildrenDirect()
public void setVersion(DataVersion version)
public DataVersion getVersion()
public void addChild(Object child_name, Node n)
public Fqn getFqn()
public void setFqn(Fqn fqn)
public NodeSPI getChildDirect(Object childName)
public Set<NodeSPI> getChildrenDirect()
public boolean hasChildrenDirect()
public Set<NodeSPI> getChildrenDirect(boolean includeMarkedForRemoval)
public boolean isDataLoaded()
public void setDataLoaded(boolean dataLoaded)
public boolean isValid()
public void setValid(boolean valid, boolean recursive)
public boolean isLockForChildInsertRemove()
public void setLockForChildInsertRemove(boolean lockForChildInsertRemove)
public void setInternalState(Map state)
public Map getInternalState(boolean onlyInternalState)
public void releaseObjectReferences(boolean recursive)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |