CORevision class documentationCORevision : NSObject <COTrackNode>
A revision contains:
- a snapshot of the inner objects
- various metadata including parent revisions (one, or two for a merge commit)
- a UUID
- the UUID of the branch that the revision was originally made on
- an arbitrary JSON dictionary for application use
For each COBranch that contains uncommitted object graph context changes (i.e. changes to the inner objects), a new revision will be created on commit.
Revisions are immutable.
History Properties and Metadata
- - (ETUUID *) UUID
Returns the revision identifier.
This revision UUID is unique accross all CoreObject stores.
- - (CORevision *) parentRevision
The revision upon which this one is based i.e. the main previous revision. For the first revision in a persistent root, returns nil (unless the persistent root is a cheap copy).
- - (CORevision *) mergeParentRevision
If this revision is the result of merging another branch into the this branch, returns the revision that was merged in, otherwise nil.
- - (ETUUID *) persistentRootUUID
Returns the persistent root UUID involved in the revision.
It is possible that this persistent root no longer exists.
- - (ETUUID *) branchUUID
Returns the branch UUID involved in the revision.
It is possible that this branch no longer exists.
- - (NSString *) localizedTypeDescription
- - (NSString *) localizedShortDescription
Returns the commit descriptor short description evaluated with the arguments provided under the key kCOCommitMetadataShortDescriptionArguments in -metadata.
History Graph Inspection
- - (BOOL) isEqualToOrAncestorOfRevision: (CORevision *)aRevision
Returns whether the receiver is equal to an ancestor of the given revision.
- - (id) initWithCache: (CORevisionCache *)aCache revisionInfo: (CORevisionInfo *)aRevInfo
Initializes and returns a new revision object to represent a precise revision number in the given revision cache.
- - (NSString *) type
Returns the revision type.
e.g. merge, persistent root creation, minor edit, etc.
Note: This type notion is a bit vague currently.