com.filenet.api.core
Interface IndependentObject

All Superinterfaces:
EngineObject, java.io.Serializable
All Known Subinterfaces:
Action, ActionConsumer, AddOn, Annotation, AsyncUpgradeQueueItem, AuditConfigurationEvent, CancelCheckoutEvent, CenteraFixedContentDevice, ChangeClassEvent, ChangeStateEvent, CheckinEvent, CheckoutEvent, ChoiceList, ClassDefinition, ClassDescription, ClassifyCompleteEvent, ClassSubscription, ClassWorkflowSubscription, CMODApplicationGroup, CMODFixedContentDevice, CMODRepository, CodeModule, ComponentRelationship, ContainmentRelationship, ContentCacheArea, ContentFederatingRepository, CreationEvent, CustomEvent, CustomObject, DatabaseStorageArea, DeletionEvent, DemoteVersionEvent, DITARenditionEngineConnection, Document, DocumentClassDefinition, DocumentClassificationAction, DocumentClassificationQueueItem, DocumentLifecycleAction, DocumentLifecyclePolicy, Domain, DynamicReferentialContainmentRelationship, EntireNetwork, Event, EventAction, EventClassDefinition, EventQueueItem, ExternalClassDescription, ExternalRepository, FileEvent, FileStorageArea, FixedContentDevice, FixedStorageArea, Folder, FreezeEvent, GenericFixedContentDevice, GetContentEvent, GetObjectEvent, Group, IICEFixedContentDevice, ImageServicesRepository, IMFixedContentDevice, IndependentlyPersistableObject, 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, Realm, ReferentialContainmentRelationship, Relationship, RenditionEngineConnection, ReplicableClassDefinition, ReplicationGroup, ReplicationJournalEntry, Repository, RetrievalEvent, SecurityPolicy, SecurityPrincipal, SecurityPropagationQueueItem, ServerInstance, Site, SnapLockFixedContentDevice, StorageArea, StoragePolicy, SubscribableClassDefinition, Subscription, TableDefinition, TakeFederatedOwnershipEvent, UnfileEvent, UnlockEvent, UpdateEvent, UpdateSecurityEvent, UpgradeAddOn, User, VerityDomainConfiguration, VerityIndexArea, VersionableClassDefinition, VersionSeries, VirtualServer, WorkflowDefinition, WorkflowEventAction, XMLPropertyMappingScript

public interface IndependentObject
extends EngineObject

Indicates objects that are independent.

An IndependentObject represents an EngineObject that has its own independent identity. Contrast this with a DependentObject, which is an EngineObject that can only exist within the scope of another object. (An example of this dependency is ContentElement; content elements are scoped to a particular Document object and cannot exist independently.) An IndependentObject can be retrieved from the server with a call to InstantiatingScope.fetchObject or Factory.<classname>.fetchInstance, whereas a DependentObject can only be fetched as a property of an IndependentObject.

An IndependentObject always has an ObjectReference, which can be obtained by calling getObjectReference. An ObjectReference provides identity information for the object.

IndependentObject.equals (which overrides java.lang.Object.equals) delegates to ObjectReference.equals for object comparisons. For information about equals implementation, see the ObjectReference interface description.

When calling the refresh methods, note that the behavior differs from that of fetch-related methods (fetchProperty and fetchProperties). The fetch-related methods retrieve the object and merge retrieved property information into the current contents of the property cache. The refresh methods retrieve the object and replace the current contents of the property cache with the retrieved property information.


Method Summary
 void fetchProperties(PropertyFilter filter)
          Retrieves this object from the server and merges existing information in the property cache with the retrieved information for the properties specified by the filter.
 void fetchProperties(java.lang.String[] propertyNames)
          Retrieves this object from the server and merges existing information in the property cache with the retrieved information for the specified properties.
 Property fetchProperty(java.lang.String propertyName, PropertyFilter filter)
          Refreshes this object and retrieves from the server the object referenced by the object-valued property specified by the propertyName parameter and populates its properties according to the filter.
 Property fetchProperty(java.lang.String propertyName, PropertyFilter filter, java.lang.Integer pageSize)
          Refreshes this object and retrieves from the server the object referenced by the object-valued property specified by the propertyName parameter and populates its properties according to the filter.
 ObjectReference getObjectReference()
          Returns an object reference that represents the object's identity.
 void refresh()
          Retrieves this object from the server and replaces existing information in the property cache with the retrieved property information.
 void refresh(PropertyFilter filter)
          Retrieves this object from the server and replaces existing information in the property cache with the retrieved information for the properties specified by the filter.
 void refresh(java.lang.String[] propertyNames)
          Retrieves this object from the server and replaces existing information in the property cache with the retrieved information for the specified properties.
 
Methods inherited from interface com.filenet.api.core.EngineObject
get_ClassDescription, getClassName, getConnection, getProperties, getSuperClasses
 

Method Detail

refresh

void refresh()
Retrieves this object from the server and replaces existing information in the property cache with the retrieved property information.


refresh

void refresh(java.lang.String[] propertyNames)
Retrieves this object from the server and replaces existing information in the property cache with the retrieved information for the specified properties.

Parameters:
propertyNames - A String array of property names identifying the properties to return with the retrieved object.
Throws:
E_INVALID_ARGUMENT - if the propertyNames parameter is null or is an empty array.

refresh

void refresh(PropertyFilter filter)
Retrieves this object from the server and replaces existing information in the property cache with the retrieved information for the properties specified by the filter.

Parameters:
filter - A PropertyFilter object that represents information for controlling which property values (and with what level of detail and recursion) to return. If null, this method returns values for all non-object properties and returns placeholders for all object-valued properties (PropertyEngineObject properties with a state of PropertyState.UNEVALUATED or PropertyState.REFERENCE); any subsequent attempts to access an object-valued property will cause an automatic round-trip to the server to fetch its value.

fetchProperties

void fetchProperties(java.lang.String[] propertyNames)
Retrieves this object from the server and merges existing information in the property cache with the retrieved information for the specified properties. If this object has changed on the server since it was last retrieved, you should call a refresh method first; otherwise, an error will be thrown.

Parameters:
propertyNames - A String array of property names identifying the properties to return with the retrieved object.
Throws:
E_INVALID_ARGUMENT - if the propertyNames parameter is null or is an empty array.
API_FETCH_MERGE_PROPERTY_ERROR - if the object has been changed on the server since it was last retrieved.

fetchProperties

void fetchProperties(PropertyFilter filter)
Retrieves this object from the server and merges existing information in the property cache with the retrieved information for the properties specified by the filter. If this object has changed on the server since it was last retrieved, you should call a refresh method first; otherwise, an error will be thrown.

Parameters:
filter - A PropertyFilter object that represents information for controlling which property values (and with what level of detail and recursion) to return. This parameter cannot be null.
Throws:
E_INVALID_ARGUMENT - if the filter parameter is null.
API_FETCH_MERGE_PROPERTY_ERROR - if the object has been changed on the server since it was last retrieved.

fetchProperty

Property fetchProperty(java.lang.String propertyName,
                       PropertyFilter filter)
Refreshes this object and retrieves from the server the object referenced by the object-valued property specified by the propertyName parameter and populates its properties according to the filter.

Parameters:
propertyName - A String specifying the name of the object-valued property.
filter - A PropertyFilter object that represents information for controlling which property values (and with what level of detail and recursion) to return. If null, this method returns values for all non-object properties and returns placeholders for all object-valued properties (PropertyEngineObject properties with a state of PropertyState.UNEVALUATED or PropertyState.REFERENCE); any subsequent attempts to access an object-valued property will cause an automatic round-trip to the server to fetch its value.
Returns:
A Property object.
Throws:
API_SAVE_BEFORE_REFRESH - if you attempt to retrieve properties for a new object that has not yet been saved.
TRANSPORT_EXPECTED_ENGINEOBJECT_RESPONSE - if the property specified by the propertyName parameter does not return an object.

fetchProperty

Property fetchProperty(java.lang.String propertyName,
                       PropertyFilter filter,
                       java.lang.Integer pageSize)
Refreshes this object and retrieves from the server the object referenced by the object-valued property specified by the propertyName parameter and populates its properties according to the filter.

Parameters:
propertyName - A String specifying the name of the object-valued property.
filter - A PropertyFilter object that represents information for controlling which property values (and with what level of detail and recursion) to return. If null, this method returns values for all non-object properties and returns placeholders for all object-valued properties (PropertyEngineObject properties with a state of PropertyState.UNEVALUATED or PropertyState.REFERENCE); any subsequent attempts to access an object-valued property will cause an automatic round-trip to the server to fetch its value.
pageSize - An Integer that specifies the maximum number of properties that will be retrieved at a time from the server. If this number is smaller than the number of properties that are specified by the filter, this method will need to be called multiple times to retrieve all of the properties. If this parameter is null, all of the properties that are specified by the filter will be retrieved in a single fetch.
Returns:
A Property object.
Throws:
API_SAVE_BEFORE_REFRESH - if you attempt to retrieve properties for a new object that has not yet been saved.
TRANSPORT_EXPECTED_ENGINEOBJECT_RESPONSE - if the property specified by the propertyName parameter does not return an object.

getObjectReference

ObjectReference getObjectReference()
Returns an object reference that represents the object's identity. The ID of an independent object is the class name and ID of the object. The ID can be a path, GUID, or name of the object.

Returns:
An ObjectReference object.


© Copyright IBM Corporation 2006, 2008. All rights reserved.