Public Methods

  Name Description
Public method CancelCheckout Cancels the check-out reservation held on this document or version series by deleting the reservation object associated with it. Any changes made to the reservation object are lost. If the reservation object is an exclusive reservation (the object's ReservationType property is set to EXCLUSIVE), the user must be the reservation owner (the reservation owner's name is the value of the reservation object's Owner property) or have both WRITE_OWNER and DELETE access rights. Note that this method is provided only as a convenience method for canceling a checkout; all it does is delete the reservation version held by the document or version series from which it is called.

After a document's reservation object is deleted, the Content Engine performs the following steps on the reserved document version:

  • Sets the IsReserved property to false.
  • Sets the ReservationType property to null.

An error occurs if the document is not checked out or is a newly created object that has never been checked in.

Public method ChangeClass Changes the class of a Content Engine object. The new class must already exist and both it and the original class must be subclasses of the same base class. The ChangeClass method does not modify the security for an object, even if the object's current security is derived from the default security for its source class. For the object's user-defined properties, the following rules apply:
  • Any user-defined properties that exist in the new class but not in the original class are set to the default value defined by the new class (or to null if there is no default defined).
  • Any user-defined properties that exist in both the original and the new class that are writable and have the same value (including null) as the default value defined in the original class will be set to the default value defined by the new class. However, any user-defined property that has had its value modified from the default value will retain that modified value in the new class.
  • Any user-defined properties whose definitions exist in the original class but not in the new class will no longer exist on the object when its class is changed.

When the class of a document object is changed, the default document lifecycle policy of the new class will only be applied to the document object's DocumentLifecyclePolicy property if both of the following scenarios occur:

  • The document has no current lifecycle policy.
  • The document is either a reservation object, or is the current version object and is not reserved.

Public method Checkout Creates a reservation object that can be modified and checked in as a new version of this document. The reservation object can be accessed from this document's Reservation property. You can either specify the type of checkout reservation (exclusive or collaborative) or use the default checkout reservation setting of the object store.

To successfully check out a document, the following requirements must be met or an exception will be thrown:

  • The document must be the current version (IsCurrentVersion property is set to true).
  • The document must not already be checked out (IsReserved property is set to false).
  • The document must be version-enabled (IsVersioningEnabled property is set to true).
  • The user must have the appropriate access rights (MINOR_VERSION to check out a minor version, or MAJOR_VERSION to check out a released version).

After a successful call to Checkout, the Content Engine performs the following steps:

  • Applies the versioning security template for the reservation state (if it exists and is enabled) to the newly created reservation object.
  • Sets the IsReserved property of the checked-out document to true.
  • Sets the ReservationType property of the checked-out document to the appropriate setting: (COLLABORATIVE or EXCLUSIVE).
Public method CreateAnnotation Creates and associates a new annotation to a specific content element of this document. To persist the created Annotation object to the object store, you must explicitly call its Save method, which will also cause the server to add it to the Annotations collection of this document.
Public method DemoteVersion Demotes the latest major version of this document to an unreleased minor version. This method changes the previous major version (if it exists) to the current released major version, but does not delete any document versions (including content) from the document's version series, therefore allowing you to continue to have access to all version changes. Note that you can demote frozen document versions and documents that are not versioning-enabled (documents whose IsVersioningEnabled property is set to false).

To successfully demote a document, the following requirements must be met or an error will occur:

  • The document must be the latest major version (VersionStatus property is set to RELEASED).
  • The document must be the current version (IsCurrentVersion property is set to true).
  • The user must have the appropriate access rights (MINOR_VERSION).
  • The document must not be reserved (IsReserved property is set to false).

After a successful call to demoteVersion, the Content Engine performs the following steps on the document version that is being demoted:

  • Applies the versioning security template (if it exists and is enabled) for the IN_PROCESS state.
  • Decrements the value of the MajorVersionNumber property by 1.
  • Sets the value of the MinorVersionNumber property to the number of the latest minor version belonging to the last major version + 1.
  • Sets the VersionStatus property to IN_PROCESS.

In addition, the Content Engine performs the following steps on the previous major document version:

  • Sets the VersionStatus property to RELEASED.
  • Applies the versioning security template for the RELEASED state.

Public method Freeze Prevents changes to the custom properties of this document version. You can freeze any checked-in document version, but you cannot freeze a reservation object. Once a document version has been frozen, it cannot be unfrozen; to change a frozen document's custom properties, a new document version must be created. Note, however, that you can change a document version's writable system properties at any time. After a successful Freeze call, the IsFrozenVersion property of the object representing the document version is set to true. An error is generated if this document is a reservation object (VersionStatus = RESERVATION) or is already a frozen version (IsFrozenVersion = true).
Public method PromoteVersion Promotes an unreleased minor version of this document to a released major version. This method changes the current released major version (if it exists) to a superseded major version, but does not delete any document versions (including content) from the document's version series, therefore allowing you to continue to have access to all version changes. Note that you can promote frozen document versions and documents that are not versioning-enabled (documents whose IsVersioningEnabled property is set to false).

To successfully promote a document, the following requirements must be met or an error will occur:

  • The document must be the latest minor version (VersionStatus property is set to IN_PROCESS).
  • The document must be the current version (IsCurrentVersion property is set to true).
  • The user must have the appropriate access rights (MAJOR_VERSION).
  • The document must not be reserved (IsReserved property is set to false).

After a successful call to PromoteVersion, the Content Engine performs the following steps on the document version that is being promoted:

  • Applies the versioning security template (if it exists and is enabled) for the RELEASED state.
  • Sets the MinorVersionNumber property to 0.
  • Increments the MajorVersionNumber property by 1.
  • Sets the VersionStatus property to RELEASED.

In addition, the Content Engine performs the following steps on the previous major document version that is being superseded:

  • Sets the VersionStatus property to SUPERSEDED.
  • Applies the versioning security template (if it exists and is enabled) for the SUPERSEDED state.

Top

See Also