Interface IndependentlyPersistableObject
-
- All Superinterfaces:
- EngineObject, IndependentObject, java.io.Serializable
- All Known Subinterfaces:
- Action, ActionConsumer, AddOn, Annotation, AsyncUpgradeQueueItem, AuditConfigurationEvent, CancelCheckoutEvent, CenteraFixedContentDevice, ChangeClassEvent, ChangeStateEvent, CheckinEvent, CheckoutEvent, ChoiceList, ClassDefinition, ClassifyCompleteEvent, ClassSubscription, ClassWorkflowSubscription, CmAbstractPersistable, CmAbstractQueueEntry, CmAbstractSearchResult, CmAbstractSequential, CmAdvancedStorageArea, CmAtmosFixedContentDevice, CmAuditDispositionPolicy, CmAuditProcessingBookmark, CmBackgroundSearch, CmBulkMoveContentJob, CmChangePreprocessorAction, CmContentBackoutQueueEntry, CmContentBackoutQueueSweep, CmContentConversionAction, CmContentConversionSettings, CmContentDeletionQueueEntry, CmContentDeletionQueueSweep, CmContentMigrationPolicy, CmContentReplicationQueueEntry, CmContentReplicationQueueSweep, CmConversionSettingsClassDefinition, CmCustomQueueSweep, CmCustomStorageDevice, CmCustomSweepJob, CmCustomSweepPolicy, CmDatabaseConnection, CmDisposalPolicy, CmEventExportStore, CmFileSystemStorageDevice, CmHitachiFixedContentDevice, CmHold, CmHoldRelationship, CmIndexRequest, CmIsilonFixedContentDevice, CmJobSweepResult, CmMarkForDeletionEvent, CmMoveContentEvent, CMODApplicationGroup, CMODFixedContentDevice, CMODRepository, CmOpenStackStorageDevice, CmPolicyControlledSweep, CmPolicySweepResult, CmQueueEntryClassDefinition, CmQueueSweep, CmRecoverEvent, CmRecoveryBin, CmRecoveryItem, CmRetentionUpdateJob, CmRetentionUpdatePolicy, CmSearchFunctionDefinition, CmSecuredStorageDevice, CmStorageDevice, CmSweep, CmSweepAction, CmSweepJob, CmSweepPolicy, CmSweepPolicyRelationship, CmSweepRelationship, CmSweepResult, CmTask, CmTaskRelationship, CmTextExtractionSettings, CmTextIndexingPreprocessorAction, CmTextSearchAffinityGroup, CmTextSearchIndexArea, CmTextSearchIndexRequest, CmTextSearchServer, CmThumbnail, CmThumbnailGenerationJob, CmThumbnailGenerationSubscription, CmThumbnailRequest, CmThumbnailRequestSweep, CmTivoliManagementClass, CmVerityIndexRequest, CodeModule, ComponentRelationship, ContainmentRelationship, ContentCacheArea, ContentFederatingRepository, CreationEvent, CustomEvent, CustomObject, DatabaseStorageArea, DeletionEvent, DemoteVersionEvent, DITARenditionEngineConnection, Document, DocumentClassDefinition, DocumentClassificationAction, DocumentClassificationQueueItem, DocumentLifecycleAction, DocumentLifecyclePolicy, Domain, DynamicReferentialContainmentRelationship, Event, EventAction, EventClassDefinition, EventQueueItem, ExternalRepository, FileEvent, FileStorageArea, FixedContentDevice, FixedStorageArea, Folder, FreezeEvent, GenericFixedContentDevice, GetContentEvent, GetObjectEvent, IICEFixedContentDevice, ImageServicesRepository, IMFixedContentDevice, IndexArea, IndexJob, InstanceSubscription, InstanceWorkflowSubscription, IsolatedRegion, Link, LockEvent, MarkingSet, ObjectChangeEvent, ObjectStore, PEConnectionPoint, PromoteVersionEvent, PropertyTemplate, PropertyTemplateBinary, PropertyTemplateBoolean, PropertyTemplateDateTime, PropertyTemplateFloat64, PropertyTemplateId, PropertyTemplateInteger32, PropertyTemplateObject, PropertyTemplateString, PublishCompleteEvent, PublishRequest, PublishRequestEvent, PublishStyleTemplate, PublishTemplate, QueryEvent, QueueItem, ReferentialContainmentRelationship, Relationship, RenditionEngineConnection, ReplicableClassDefinition, ReplicationGroup, ReplicationJournalEntry, Repository, RetrievalEvent, SecurityPolicy, SecurityPropagationQueueItem, ServerInstance, Site, SnapLockFixedContentDevice, StorageArea, StoragePolicy, StoredSearch, SubscribableClassDefinition, Subscription, TableDefinition, TakeFederatedOwnershipEvent, TivoliFixedContentDevice, UnfileEvent, UnlockEvent, UpdateEvent, UpdateSecurityEvent, UpgradeAddOn, VerityDomainConfiguration, VerityIndexArea, VersionableClassDefinition, VersionSeries, VirtualServer, WorkflowDefinition, WorkflowEventAction, XMLPropertyMappingScript
public interface IndependentlyPersistableObject extends IndependentObject
Represents a persistableIndependentObjectthat you can directly create, update, and delete.
-
-
Method Summary
Methods Modifier and Type Method and Description voidaddPendingAction(PendingAction pa)Adds the specified pending action to this object'sPendingActionscollection.voidclearPendingActions()Clears out the list of pending actions for this object.voiddelete()Adds aDeletepending action to this object'sPendingActionscollection.java.lang.IntegergetAccessAllowed()Returns a value representing a bit mask of access rights granted to the user requesting this object.PendingAction[]getPendingActions()Returns the pending actions for this object.java.lang.IntegergetUpdateSequenceNumber()Returns the update sequence number (USN) for this object.java.lang.BooleanisCurrent()Returns a value indicating whether or not the state of this object is consistent with its state in the repository.voidsave(RefreshMode refreshMode)Saves changes made to this object.voidsave(RefreshMode refreshMode, PropertyFilter filter)Saves changes made to this object.voidsetUpdateSequenceNumber(java.lang.Integer val)Sets the update sequence number (USN) for this object.-
Methods inherited from interface com.filenet.api.core.IndependentObject
fetchProperties, fetchProperties, fetchProperty, fetchProperty, getObjectReference, refresh, refresh, refresh
-
Methods inherited from interface com.filenet.api.core.EngineObject
get_ClassDescription, getClassName, getConnection, getProperties, getSuperClasses
-
-
-
-
Method Detail
-
getUpdateSequenceNumber
java.lang.Integer getUpdateSequenceNumber()
Returns the update sequence number (USN) for this object. You can use the returned value to determine if the object has been modified since some earlier fetch of the same object.An
IndependentlyPersistableObjecthas an update sequence number (USN), which is an integer value on the object that protects it against concurrent updates. The USN value increases monotonically with each update to the object. When you update the object, the USN from the retrieved object is checked against the currently persisted USN value. If the values are different, the operation fails.As a special case, a USN value of
nullcauses the server-side check to be skipped during updates (this is sometimes called "unprotected update"). AnIndependentlyPersistableObjectinstantiated by calling one of thegetInstancemethods on aFactoryclass (such asFactory.CustomObject.getInstance) does not fetch the object from the server and so is unaware of the persisted USN. CallinggetUpdateSequenceon such an object returnsnull.- Returns:
- An integer representing the USN.
-
setUpdateSequenceNumber
void setUpdateSequenceNumber(java.lang.Integer val)
Sets the update sequence number (USN) for this object. You can cause update sequence checking to be skipped for this object by setting the USN value tonull.- Parameters:
val- The new value for the USN, ornullto suppress update sequence checking.
-
isCurrent
java.lang.Boolean isCurrent()
Returns a value indicating whether or not the state of this object is consistent with its state in the repository.When one or more of the object's properties are "dirty" (have been marked as changed since the last time they were saved),
isCurrentreturnsFalse. You can then do one of the following:- save changes to the persistent store. (You can either call the
savemethod or add the object to anUpdatingBatchthen callupdateBatch, which effectively callssaveon eachIndependentlyPersistableObjectin the batch.) - call the object's
refreshmethod to cancel the changes and restore the object's state to that of the persistent store. - remove dirty properties by calling
removeFromCache.
- Returns:
- A
Booleanexpression representing the object state. ReturnsTrueif the object's properties have not been changed; otherwise, returnsFalse(the object has dirty properties).
- save changes to the persistent store. (You can either call the
-
delete
void delete()
Adds aDeletepending action to this object'sPendingActionscollection. You must subsequently commit the change to the repository. (SeePendingActionfor more information about pending actions.)For
VersionSeries, all document versions are deleted.For
CmRecoveryItem, this method deletes the item contained within theCmRecoveryBinobject. It also deletes all recoverable objects represented by theCmRecoveryItemobject.
-
save
void save(RefreshMode refreshMode)
Saves changes made to this object. You can optionally refresh all of the object's properties.- Parameters:
refreshMode- Specifies whether or not to refresh all of the object's properties.
-
save
void save(RefreshMode refreshMode, PropertyFilter filter)
Saves changes made to this object. You can optionally refresh a selected set of the object's properties using thefilterparameter.- Parameters:
refreshMode- Specifies whether or not to refresh all of the object's properties.filter- APropertyFilterobject that represents information for controlling which property values (and with what level of detail and recursion) to refresh. Specifyingnullis the same as callingsave(refreshMode).
-
getPendingActions
PendingAction[] getPendingActions()
Returns the pending actions for this object.- Returns:
- An array of
PendingActionobjects.
-
addPendingAction
void addPendingAction(PendingAction pa)
Adds the specified pending action to this object'sPendingActionscollection. (Note that you probably won't directly manipulate an object's pending actions in this manner. You will more likely call wrapper methods such asdeleteandcheckin, which add a pending action to the collection.)- Parameters:
pa- APendingActionobject.
-
clearPendingActions
void clearPendingActions()
Clears out the list of pending actions for this object. For example, if you calleddelete()without subsequently callingsave, then calledclearPendingActions(), theDeletepending action would no longer be in the object's pending actions list. This effectively cancels changes not yet saved.
-
getAccessAllowed
java.lang.Integer getAccessAllowed()
Returns a value representing a bit mask of access rights granted to the user requesting this object.- Returns:
- An integer representing the access rights granted to the requesting user.
-
-