public class StubCDORevision extends AbstractCDORevision
DEPTH_INFINITE, DEPTH_NONE, FIRST_VERSION, MAIN_BRANCH_ID, PERMISSION_PROVIDER, UNCHUNKED
INVALID_DATE, UNSPECIFIED_DATE
UNSPECIFIED_VERSION
NIL
Modifier | Constructor and Description |
---|---|
|
StubCDORevision(EClass eClass) |
protected |
StubCDORevision(InternalCDOClassInfo classInfo) |
Modifier and Type | Method and Description |
---|---|
void |
add(EStructuralFeature feature,
int index,
Object value) |
void |
adjustBranches(CDOBranchManager newBranchManager) |
boolean |
adjustReferences(CDOReferenceAdjuster referenceAdjuster) |
boolean |
bypassPermissionChecks(boolean on)
Enables or disables permission checking for this revision.
|
void |
clear(EStructuralFeature feature) |
EStructuralFeature[] |
clearValues() |
InternalCDORevisionDelta |
compare(CDORevision origin) |
int |
compareTo(CDOBranchPoint o) |
boolean |
contains(EStructuralFeature feature,
Object value) |
void |
convertEObjects(CDOIDProvider oidProvider) |
InternalCDORevision |
copy() |
void |
freeze() |
Object |
get(EStructuralFeature feature,
int index) |
InternalCDOBranch |
getBranch()
Returns the branch of this branch version.
|
Object |
getContainerID() |
int |
getContainingFeatureID()
Provides the input to the calculation of the feature in the container revision that actually holds this revision.
|
CDOID |
getID() |
CDOList |
getList(EStructuralFeature feature) |
CDOList |
getList(EStructuralFeature feature,
int size) |
CDOPermission |
getPermission() |
CDOID |
getResourceID() |
String |
getResourceNodeName() |
long |
getRevised() |
long |
getTimeStamp()
Returns the time stamp of this branch point, or the fixed special time stamp
unspecified if this branch point marks the head of a branch. |
Object |
getValue(EStructuralFeature feature)
Should never return
CDORevisionData.NIL |
int |
getVersion()
Returns the version number of this branch version.
|
int |
hashCode(EStructuralFeature feature) |
int |
indexOf(EStructuralFeature feature,
Object value) |
boolean |
isEmpty(EStructuralFeature feature) |
boolean |
isFrozen() |
boolean |
isListPreserving() |
boolean |
isUnchunked() |
int |
lastIndexOf(EStructuralFeature feature,
Object value) |
void |
merge(CDORevisionDelta delta) |
Object |
move(EStructuralFeature feature,
int targetIndex,
int sourceIndex) |
void |
read(CDODataInput in) |
boolean |
readValues(CDODataInput in) |
Object |
remove(EStructuralFeature feature,
int index) |
Object |
set(EStructuralFeature feature,
int index,
Object value) |
void |
setBranchPoint(CDOBranchPoint branchPoint) |
void |
setContainerID(Object containerID) |
void |
setContainingFeatureID(int containingFeatureID) |
void |
setID(CDOID id) |
void |
setList(EStructuralFeature feature,
InternalCDOList list) |
void |
setListPreserving()
The default behavior of a revision for calls to the
InternalCDORevision.clear(EStructuralFeature) and
InternalCDORevision.unset(EStructuralFeature) methods is to set the feature's value to null (discarding the
value itself, a List). |
void |
setPermission(CDOPermission permission) |
void |
setResourceID(CDOID resourceID) |
void |
setRevised(long revised) |
void |
setUnchunked() |
Object |
setValue(EStructuralFeature feature,
Object value) |
void |
setVersion(int version) |
int |
size(EStructuralFeature feature) |
Object[] |
toArray(EStructuralFeature feature) |
<T> T[] |
toArray(EStructuralFeature feature,
T[] array) |
void |
unset(EStructuralFeature feature) |
void |
write(CDODataOutput out,
int referenceChunk) |
void |
write(CDODataOutput out,
int referenceChunk,
CDOBranchPoint securityContext) |
void |
writeValues(CDODataOutput out,
int referenceChunk) |
accept, accept, adjustForCommit, data, equals, getAllPersistentFeatures, getClassInfo, getEClass, getFeatureIndex, getProperRevision, getRevisionForID, hashCode, initClassInfo, isHistorical, isReadable, isResource, isResourceFolder, isResourceNode, isValid, isValid, isWritable, revision, toString
public StubCDORevision(EClass eClass)
protected StubCDORevision(InternalCDOClassInfo classInfo)
public int compareTo(CDOBranchPoint o)
public void setID(CDOID id)
public void setVersion(int version)
public void setBranchPoint(CDOBranchPoint branchPoint)
public void setRevised(long revised)
public void setResourceID(CDOID resourceID)
public void setContainerID(Object containerID)
public void setContainingFeatureID(int containingFeatureID)
public void add(EStructuralFeature feature, int index, Object value)
public void clear(EStructuralFeature feature)
public Object move(EStructuralFeature feature, int targetIndex, int sourceIndex)
public Object remove(EStructuralFeature feature, int index)
public Object set(EStructuralFeature feature, int index, Object value)
public void unset(EStructuralFeature feature)
public Object getValue(EStructuralFeature feature)
InternalCDORevision
CDORevisionData.NIL
public Object setValue(EStructuralFeature feature, Object value)
public void setList(EStructuralFeature feature, InternalCDOList list)
public CDOList getList(EStructuralFeature feature)
public CDOList getList(EStructuralFeature feature, int size)
size
- the initialCapacity of a new list to be created if this revision has no list so far (its size will always
be 0), or -1 to skip list creation and return null
in this case.public void read(CDODataInput in) throws IOException
IOException
public boolean readValues(CDODataInput in) throws IOException
IOException
public void write(CDODataOutput out, int referenceChunk) throws IOException
IOException
public void write(CDODataOutput out, int referenceChunk, CDOBranchPoint securityContext) throws IOException
IOException
public void writeValues(CDODataOutput out, int referenceChunk) throws IOException
IOException
public void convertEObjects(CDOIDProvider oidProvider)
public int getVersion()
CDOBranchVersion
public long getRevised()
public InternalCDORevisionDelta compare(CDORevision origin)
public void merge(CDORevisionDelta delta)
public InternalCDORevision copy()
public CDOID getID()
public InternalCDOBranch getBranch()
CDOBranchVersion
public long getTimeStamp()
CDOBranchPoint
unspecified
if this branch point marks the head
of a branch.public CDOID getResourceID()
public Object getContainerID()
public int getContainingFeatureID()
CDORevisionData
Usage Example:
CDORevision revision = ...;
CDORevision container = Util.getRevision(revision.data().getContainerID());
int containingFeatureID = revision.data().getContainingFeatureID();
EStructuralFeature feature = containingFeatureID <= InternalEObject.EOPPOSITE_FEATURE_BASE ?
container.getEClass().getEStructuralFeature(InternalEObject.EOPPOSITE_FEATURE_BASE - containingFeatureID) :
((EReference)revision.getEClass().getEStructuralFeature(containingFeatureID)).getEOpposite();
public Object get(EStructuralFeature feature, int index)
public int size(EStructuralFeature feature)
public boolean isEmpty(EStructuralFeature feature)
public boolean contains(EStructuralFeature feature, Object value)
public int indexOf(EStructuralFeature feature, Object value)
public int lastIndexOf(EStructuralFeature feature, Object value)
public <T> T[] toArray(EStructuralFeature feature, T[] array)
public Object[] toArray(EStructuralFeature feature)
public int hashCode(EStructuralFeature feature)
public boolean adjustReferences(CDOReferenceAdjuster referenceAdjuster)
public void adjustBranches(CDOBranchManager newBranchManager)
public EStructuralFeature[] clearValues()
public String getResourceNodeName()
public CDOPermission getPermission()
public void setPermission(CDOPermission permission)
public boolean bypassPermissionChecks(boolean on)
InternalCDORevision
This method is used on the client side if the framework changes the revision on another user's behalf, e.g., during invalidation or general revision copying. It's safe to offer this method on the client side because the server is always the permission checking authority (during load or commit).
public boolean isListPreserving()
public void setListPreserving()
InternalCDORevision
InternalCDORevision.clear(EStructuralFeature)
and
InternalCDORevision.unset(EStructuralFeature)
methods is to set the feature's value to null (discarding the
value itself, a List). By calling this InternalCDORevision.setListPreserving()
method the default behavior
is changed; instead of setting the feature's value to null, the List.clear()
method is
called on the feature's list instance.public void freeze()
public boolean isFrozen()
public boolean isUnchunked()
public void setUnchunked()
Copyright (c) 2011-2015 Eike Stepper (Berlin, Germany) and others.