Package org.apache.jackrabbit.core
Class ItemData
- java.lang.Object
-
- org.apache.jackrabbit.core.ItemData
-
- Direct Known Subclasses:
AbstractNodeData
,PropertyData
public abstract class ItemData extends Object
Data object referenced by differentItemImpl
instances that all represent the same item, i.e. items having the sameItemId
.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ItemData(ItemId id)
Create a new instance of this class.protected
ItemData(ItemState state, ItemManager itemMgr)
Create a new instance of this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ItemDefinition
getDefinition()
Return the associated item definition.ItemId
getId()
Return the id associated with this item.NodeId
getParentId()
Return the parent id of this item.ItemState
getState()
Return the associated item state.int
getStatus()
Return the status.boolean
isNode()
Return a flag indicating whether item is a node.protected void
setDefinition(ItemDefinition definition)
Set the associated item definition.protected void
setState(ItemState state)
Set the associated item state.protected void
setStatus(int status)
Set the status.String
toString()
-
-
-
Constructor Detail
-
ItemData
protected ItemData(ItemState state, ItemManager itemMgr)
Create a new instance of this class.- Parameters:
state
- item stateitemMgr
- item manager
-
ItemData
protected ItemData(ItemId id)
Create a new instance of this class.- Parameters:
id
- item id
-
-
Method Detail
-
getState
public ItemState getState()
Return the associated item state.- Returns:
- item state
-
setState
protected void setState(ItemState state)
Set the associated item state.- Parameters:
state
- item state
-
getDefinition
public ItemDefinition getDefinition() throws RepositoryException
Return the associated item definition.- Returns:
- item definition
- Throws:
RepositoryException
- if the definition cannot be retrieved.
-
setDefinition
protected void setDefinition(ItemDefinition definition)
Set the associated item definition.- Parameters:
definition
- item definition
-
getStatus
public int getStatus()
Return the status.- Returns:
- status
-
setStatus
protected void setStatus(int status)
Set the status.- Parameters:
status
-
-
isNode
public boolean isNode()
Return a flag indicating whether item is a node.- Returns:
true
if this item is a node;false
otherwise.
-
getId
public ItemId getId()
Return the id associated with this item.- Returns:
- item id
-
getParentId
public NodeId getParentId()
Return the parent id of this item.- Returns:
- parent id
-
-