Class RevisionCollection
A collection of all revisions in a document. The collection is lazy — it walks the document tree on each enumeration to collect current (unresolved) revisions.
Use AcceptAll() to accept every revision, or RejectAll() to reject every revision, or iterate and call Accept() / Reject() selectively.
Inherited Members
Namespace: DRIT.Document
Assembly: DRIT.Document.dll
Syntax
public class RevisionCollection : IEnumerable<Revision>, IEnumerable
Properties
Groups
Gets a snapshot of the current revisions grouped by adjacent author.
Declaration
public RevisionGroupCollection Groups { get; }
Property Value
| Type | Description |
|---|---|
| RevisionGroupCollection |
Methods
AcceptAll()
Accept every revision in the document.
Insert revisions: keep content, remove marks. Delete revisions: remove content. Format revisions: keep new format, remove marks.
Declaration
public void AcceptAll()
GetEnumerator()
Enumerate all unresolved revisions in the document.
Declaration
public IEnumerator<Revision> GetEnumerator()
Returns
| Type | Description |
|---|---|
| IEnumerator<Revision> |
GetGroups(IRevisionCriteria)
Gets current revisions matching the criteria, grouped by adjacent author.
Declaration
public RevisionGroupCollection GetGroups(IRevisionCriteria criteria)
Parameters
| Type | Name | Description |
|---|---|---|
| IRevisionCriteria | criteria | The criteria used to select revisions. |
Returns
| Type | Description |
|---|---|
| RevisionGroupCollection | Matching revision groups in document order. |
GetRevisions(IRevisionCriteria)
Gets the current revisions that match the supplied criteria.
Declaration
public IEnumerable<Revision> GetRevisions(IRevisionCriteria criteria)
Parameters
| Type | Name | Description |
|---|---|---|
| IRevisionCriteria | criteria | The criteria used to select revisions. |
Returns
| Type | Description |
|---|---|
| IEnumerable<Revision> | Matching unresolved revisions in document order. |
GetRevisions(RevisionsView)
Gets revisions relevant to the original or final document view.
Declaration
public IEnumerable<Revision> GetRevisions(RevisionsView view)
Parameters
| Type | Name | Description |
|---|---|---|
| RevisionsView | view | The requested document view. |
Returns
| Type | Description |
|---|---|
| IEnumerable<Revision> | Revisions relevant to the requested view. |
RejectAll()
Reject every revision in the document.
Insert revisions: remove content. Delete revisions: keep content, remove marks. Format revisions: restore previous format, remove marks.
Declaration
public void RejectAll()