public class PropertyState extends ItemState
PropertyState represents the state of a Property.overlayedState, status, STATUS_EXISTING, STATUS_EXISTING_MODIFIED, STATUS_EXISTING_REMOVED, STATUS_NEW, STATUS_STALE_DESTROYED, STATUS_UNDEFINED| Constructor and Description |
|---|
PropertyState(PropertyId id,
int initialStatus,
boolean isTransient)
Create a new
PropertyState |
PropertyState(PropertyState overlayedState,
int initialStatus,
boolean isTransient)
Constructs a new property state that is initially connected to an
overlayed state.
|
| Modifier and Type | Method and Description |
|---|---|
long |
calculateMemoryFootprint()
Returns an estimate of the memory size of this property state.
|
void |
copy(ItemState state,
boolean syncModCount)
Copy state information from another state into this state
|
ItemId |
getId()
Returns the identifier of this item.
|
Name |
getName()
Returns the name of this property.
|
NodeId |
getParentId()
Returns the NodeId of the parent
NodeState or null
if either this item state represents the root node or this item state is
'free floating', i.e. |
PropertyId |
getPropertyId()
Returns the identifier of this property.
|
int |
getType()
Returns the type of this property.
|
InternalValue[] |
getValues()
Returns the value(s) of this property.
|
boolean |
isMultiValued()
Returns true if this property is multi-valued, otherwise false.
|
boolean |
isNode()
Determines if this item state represents a node.
|
void |
setMultiValued(boolean multiValued)
Sets the flag indicating whether this property is multi-valued.
|
void |
setType(int type)
Sets the type of this property.
|
void |
setValues(InternalValue[] values)
Sets the value(s) of this property.
|
connect, discard, disconnect, getContainer, getModCount, getOverlayedState, getStatus, hasOverlayedState, isConnected, isStale, isTransient, notifyStateCreated, notifyStateDestroyed, notifyStateDiscarded, notifyStateUpdated, reconnect, setContainer, setModCount, setStatuspublic PropertyState(PropertyState overlayedState, int initialStatus, boolean isTransient)
overlayedState - the backing property state being overlayedinitialStatus - the initial status of the property state objectisTransient - flag indicating whether this state is transient or notpublic PropertyState(PropertyId id, int initialStatus, boolean isTransient)
PropertyStateid - id of the propertyinitialStatus - the initial status of the property state objectisTransient - flag indicating whether this state is transient or notpublic void copy(ItemState state, boolean syncModCount)
public boolean isNode()
isNode in class ItemStateItemState.isNode()public ItemId getId()
public PropertyId getPropertyId()
public NodeId getParentId()
NodeState or null
if either this item state represents the root node or this item state is
'free floating', i.e. not attached to the repository's hierarchy.getParentId in class ItemStateNodeState's Idpublic Name getName()
public void setType(int type)
type - the type to be setPropertyTypepublic void setMultiValued(boolean multiValued)
multiValued - flag indicating whether this property is multi-valuedpublic int getType()
PropertyTypepublic boolean isMultiValued()
public void setValues(InternalValue[] values)
values - the new valuespublic InternalValue[] getValues()
public long calculateMemoryFootprint()
calculateMemoryFootprint in class ItemStateCopyright © 2004–2020 The Apache Software Foundation. All rights reserved.