FileNet Content Services
Java Connector v3.0

com.filenet.wcm.api
Interface Folder

All Superinterfaces:
BaseObject, GettableObject, LockableObject, ReadableMetadataObject, ReadableSecurityObject, java.io.Serializable, ValueObject, WorkflowTarget, WriteableMetadataObject, WriteableSecurityObject
All Known Subinterfaces:
Folder

public interface Folder
extends BaseObject, WorkflowTarget, WriteableSecurityObject, GettableObject, LockableObject

A Folder object represents a container that can hold other objects. These objects can be subfolders and any object that implements the ContainableObject interface. Folders are not versionable. Also, there is only one folder class -- _BASE_FOLDER -- for all folders.

Each Content Services object store has an automatically-created root folder that represents the default root associated with the object store. You cannot create or delete a root folder, but you can access it by calling the getRootFolder method on an ObjectStore object or by retrieving the object's RootFolder property.

To create a Folder object, call one of the addSubFolder methods on the parent folder.

You can instantiate a persisted Folder object in the following ways:

You can also instantiate a Folder object by first instantiating a Folders collection, then returning a Folder object from the collection. For ways to instantiate a Folders collection, see the Folders interface.

See Also:
CS Java Toolkit Developer's Guide

Field Summary
 
Fields inherited from interface com.filenet.wcm.api.BaseObject
EXPORT_DEFAULT, EXPORT_ENCODED_CONTENT, EXPORT_FULL, EXPORT_OBJECT_ID, EXPORT_OBJECT_SECURITY, IMPORT_DEFAULT, IMPORT_OBJECT_ID, IMPORT_OWNER, IMPORT_PERMISSIONS, TYPE_ACTIVE_MARKING, TYPE_ANNOTATION, TYPE_ANY, TYPE_CBR_ENGINE_TYPE, TYPE_CHOICE, TYPE_CHOICELIST, TYPE_CLASS_SUBSCRIPTION, TYPE_CLASSDEFINITION, TYPE_CLASSDESCRIPTION, TYPE_COLUMN_DEFINITION, TYPE_COMPUTER, TYPE_CONTENT_CACHE_SERVICE, TYPE_CONTENT_MGR_SERVICE, TYPE_CONTENT_REFERENCE, TYPE_CONTENT_TRANSFER, TYPE_CUSTOMOBJECT, TYPE_DOCUMENT, TYPE_DOCUMENT_CLASSIFICATION_ACTION, TYPE_DOCUMENT_LIFECYCLE_ACTION, TYPE_DOCUMENT_LIFECYCLE_POLICY, TYPE_DOCUMENTSTATE, TYPE_DOMAIN, TYPE_DYNAMIC_REFERENTIAL_CONTAINMENT_RELATIONSHIP, TYPE_ENTIRENETWORK, TYPE_EVENT, TYPE_EVENT_ACTION, TYPE_FEATURE_ADD_ON, TYPE_FILESTORE, TYPE_FOLDER, TYPE_GROUP, TYPE_INSTANCE_SUBSCRIPTION, TYPE_LINK, TYPE_LOCALIZED_STRING, TYPE_MARKING_SET, TYPE_MULTIPLEVALUES, TYPE_OBJECT_STORE, TYPE_OBJECTSET, TYPE_OBJSTORE_SERVICE, TYPE_PERMISSION, TYPE_PROPERTY_DEFINITION, TYPE_PROPERTYDESCRIPTION, TYPE_PROPERTYDESCRIPTIONS, TYPE_PUBLISH_REQUEST, TYPE_PUBLISH_TEMPLATE, TYPE_READONLY_OBJECT_SET, TYPE_REALM, TYPE_REFERENTIAL_CONTAINMENT_RELATIONSHIP, TYPE_SECURITY_POLICY, TYPE_SECURITY_TEMPLATE, TYPE_STORAGE_POLICY, TYPE_STORED_SEARCH, TYPE_STYLE_TEMPLATE, TYPE_SUBSCRIPTION, TYPE_TABLE_DEFINITION, TYPE_TRANSIENT, TYPE_USER, TYPE_VERSIONSERIES, TYPE_WORKFLOW_CLASS_SUBSCRIPTION, TYPE_WORKFLOW_INSTANCE_SUBSCRIPTION, TYPE_WORKFLOWDEFINITION, TYPE_XML_PROPERTY_MAPPING_SCRIPT
 
Method Summary
 Folder addSubFolder(java.lang.String folderName, Properties folderProps, Permissions folderACLs)
          Creates a subfolder of this Folder object.
 Folder addSubFolder(java.lang.String folderName, java.lang.String folderClass, Properties folderProps, Permissions folderACLs)
          Creates a folder as a subfolder of this Folder object.
 void applySecurityTemplate(java.lang.String applyStateId)
          

Not Implemented in CS Java Connector v3.0.

 void changeClass(java.lang.String classId, Properties props, Permissions perms)
          

Not Implemented in CS Java Connector v3.0.

 void delete()
          Deletes this Folder object if the user has appropriate permissions and there is no constraint upon it that makes it unable to be deleted.
 int getAccessMask()
          

Not Implemented in CS Java Connector v3.0.

 BaseObjects getContainees()
          Returns a collection of objects that are contained in this Folder object.
 BaseObjects getContainees(boolean includeHidden)
          Returns a collection of objects that are contained in this Folder object.
 BaseObjects getContainees(int[] typesReturned)
          Returns a collection of objects of the specified type or types that are filed in this Folder object.
 BaseObjects getContainees(int[] typesReturned, boolean includeHidden)
          Returns a collection of objects of the specified type or types that are filed in this Folder object.
 BaseObjects getContainees(int[] typesReturned, java.lang.String[] propNames)
          Returns a collection of objects of the specified type or types -- along with their specified properties -- that are filed in this Folder object.
 BaseObjects getContainees(int[] typesReturned, java.lang.String[] propNames, boolean includeHidden)
          Returns a collection of objects of the specified type or types -- along with their specified properties -- that are filed in this Folder object.
 java.lang.String getContaineesXML(int[] typesReturned, java.lang.String[] propNames)
          Returns a string in XML that represents a collection of objects (and their requested properties) of the specified type or types that are contained in this Folder object.
 java.lang.String getContaineesXML(int[] typesReturned, java.lang.String[] propNames, boolean includeHidden)
          Returns a string in XML that represents a collection of objects (and their requested properties) of the specified type or types that are contained in this Folder object.
 Links getHeadLinks(java.lang.String[] propNames)
          

Not Implemented in CS Java Connector v3.0.

 java.lang.String getHeadLinksXML(java.lang.String[] propNames)
          

Not Implemented in CS Java Connector v3.0.

 Folder getParentFolder()
          Returns a reference to the parent folder of this Folder object.
 java.lang.String getParentFolderXML()
          Returns a string in XML that represents a reference to the parent folder of this Folder object.
 java.lang.String getPermissionsXML()
          Retrieves a string in XML that represents the permissions for this Folder object.
 Subscriptions getSubscriptions(java.lang.String[] propNames)
          

Not Implemented in CS Java Connector v3.0.

 Links getTailLinks(java.lang.String[] propNames)
          

Not Implemented in CS Java Connector v3.0.

 java.lang.String getTailLinksXML(java.lang.String[] propNames)
          

Not Implemented in CS Java Connector v3.0.

 Permissions getUserAccess()
          

Not Implemented in CS Java Connector v3.0.

 Permissions getUserAccess(java.lang.String collectionType)
          

Not Implemented in CS Java Connector v3.0.

 Permissions getUserAccess(java.lang.String collectionType, java.lang.String userId)
          

Not Implemented in CS Java Connector v3.0.

 Permissions getUserAccess(java.lang.String collectionType, java.lang.String userId, java.lang.String domain)
          Deprecated. Use (collectionType, userId) form of this method.
 java.lang.String getUserAccessXML()
          

Not Implemented in CS Java Connector v3.0.

 void move(Folder destinationParent)
          Moves this Folder object and all of its sub-folders and contents from its current parent folder to the parent folder specified by the destinationFolder parameter.
 Event raiseEvent(java.lang.String classId, Properties props)
          

Not Implemented in CS Java Connector v3.0.

 
Methods inherited from interface com.filenet.wcm.api.BaseObject
equals, exportObject, getClassId, getId, getName, getObjectStoreId, getObjectType, getSession, hashCode, thisBaseObject
 
Methods inherited from interface com.filenet.wcm.api.WorkflowTarget
getWorkflowSubscriptions, getWorkflowSubscriptionsXML, getWorkflowSubscriptionsXML
 
Methods inherited from interface com.filenet.wcm.api.WriteableSecurityObject
setPermissions, setPermissions
 
Methods inherited from interface com.filenet.wcm.api.WriteableMetadataObject
setProperties
 
Methods inherited from interface com.filenet.wcm.api.ReadableMetadataObject
getProperties, getProperties, getPropertiesXML, getPropertyBinaryValue, getPropertyBooleanValue, getPropertyDateValue, getPropertyDoubleValue, getPropertyIntValue, getPropertyStringValue, getPropertyValue, getPropertyValuesValue, refresh, refresh
 
Methods inherited from interface com.filenet.wcm.api.ReadableSecurityObject
getPermissions, getPermissions
 
Methods inherited from interface com.filenet.wcm.api.LockableObject
extendLock, extendLock, isLocked, lock, unlock, unlock
 

Method Detail

getContainees

public BaseObjects getContainees(int[] typesReturned)
Returns a collection of objects of the specified type or types that are filed in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER.

For this version of the Content Services Java Connector, you can specify the following types in the integer array:

For Document objects, the following default properties are returned: idmDocCurVerNum, idmAddedByGroup, idmVerDocId, idmAnnotation, idmVerFileName, idmDateAdded, idmName, idmPublish, idmVWVersion, idmVerCheckoutPending, idmVerCheckinUser, idmSearch, idmCDBehaviorId,idmVerReclaimPending, idmVerPermanent, idmDocOwner, idmDocType, idmAddedByUser, idmDocProtected, idmComment, idmDateAccessed, idmId, idmVerAvailStat, idmDocCurVerDate,idmVerCreateDate, idmVerCD, idmVerId,idmFilterQuery,idmVerCsiStatus.

The returned Document properties are a subset of all the properites stored in the com.filenet.Panagon.Document fields.

For Folder objects, the following default properties are returned: idmId, idmDateAdded, idmFolderReplType, idmName, idmAddedByUser, idmComment.

The returned Folder properties are a subset of all the properites stored in the com.filenet.Panagon.Folder fields.

To return properties other than the default properties returned with a Document or Folder object, call the getContainees(typesReturned, propNames) form of this method.

To return all objects filed in a folder, use the getContainees() form of this method.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

Returns:
A BaseObjects collection that contains objects of the specified types that are contained in this Folder object. If no objects of the specified types are contained in this Folder object, then this method returns an empty BaseObjects collection.

getContainees

public BaseObjects getContainees(int[] typesReturned,
                                 boolean includeHidden)
Returns a collection of objects of the specified type or types that are filed in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER.

For this version of the Content Services Java Connector, you can specify the following types in the integer array:

For Document objects, the following default properties are returned: idmDocCurVerNum, idmAddedByGroup, idmVerDocId, idmAnnotation, idmVerFileName, idmDateAdded, idmName, idmPublish, idmVWVersion, idmVerCheckoutPending, idmVerCheckinUser, idmSearch, idmCDBehaviorId,idmVerReclaimPending, idmVerPermanent, idmDocOwner, idmDocType, idmAddedByUser, idmDocProtected, idmComment, idmDateAccessed, idmId, idmVerAvailStat, idmDocCurVerDate,idmVerCreateDate, idmVerCD, idmVerId,idmFilterQuery,idmVerCsiStatus.

The returned Document properties are a subset of all the properites stored in the com.filenet.Panagon.Document fields.

For Folder objects, the following default properties are returned: idmId, idmDateAdded, idmFolderReplType, idmName, idmAddedByUser, idmComment.

The returned Folder properties are a subset of all the properites stored in the com.filenet.Panagon.Folder fields.

To return properties other than the default properties returned with a Document or Folder object, call the getContainees(typesReturned, propNames) form of this method.

To return all objects filed in a folder, use the getContainees() form of this method.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

includeHidden - Requires a boolean value; however, the value is ignored by the CS Java Connector.

Returns:
A BaseObjects collection that contains objects of the specified types that are contained in this Folder object. If no objects of the specified types are contained in this Folder object, then this method returns an empty BaseObjects collection.

getContainees

public BaseObjects getContainees(int[] typesReturned,
                                 java.lang.String[] propNames)
Returns a collection of objects of the specified type or types -- along with their specified properties -- that are filed in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER. For this version of the Content Services Java Connector, you can specify the following types in the integer array:

Specify the properties to return in the propNames array. If you specify a property and an object does not have that property, the property is ignored for that object. Therefore, if you specify several types of objects in typesReturned, and you specify properties that are specific to a certain object type in propNames, the objects are returned with their appropriate properties.

If the propNames parameter is null or an empty array, this method retrieves an initial set of hard-coded properties. However, because this set can vary from release to release, we recommend you specify the properties your application requires in the propNames array.

For enhanced performance, use this form of the method rather than the getContainees() form if you know exactly what properties you want to retrieve -- even if the default properties returned by getContainees() include the specific properties that you're interested in.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

propNames - A String array whose elements specify the symbolic names of the properties to retrieve. (If you pass in a null, you must first explicitly cast it to a String[] to avoid a compilation error.)

Returns:
A BaseObjects collection that contains objects of the specified types that are contained in this Folder object. If no objects of the specified types are contained in this Folder object, then this method returns an empty BaseObjects collection.


getContainees

public BaseObjects getContainees(int[] typesReturned,
                                 java.lang.String[] propNames,
                                 boolean includeHidden)
Returns a collection of objects of the specified type or types -- along with their specified properties -- that are filed in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER. For this version of the Content Services Java Connector, you can specify the following types in the integer array:

Specify the properties to return in the propNames array. If you specify a property and an object does not have that property, the property is ignored for that object. Therefore, if you specify several types of objects in typesReturned, and you specify properties that are specific to a certain object type in propNames, the objects are returned with their appropriate properties.

If the propNames parameter is null or an empty array, this method retrieves an initial set of hard-coded properties. However, because this set can vary from release to release, we recommend you specify the properties your application requires in the propNames array.

For enhanced performance, use this form of the method rather than the getContainees() form if you know exactly what properties you want to retrieve -- even if the default properties returned by getContainees() include the specific properties that you're interested in.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

propNames - A String array whose elements specify the symbolic names of the properties to retrieve.

includeHidden - - Requires a boolean value; however, the value is ignored by the CS Java Connector.

Returns:
A BaseObjects collection that contains objects of the specified types that are contained in this Folder object. If no objects of the specified types are contained in this Folder object, then this method returns an empty BaseObjects collection.


getContainees

public BaseObjects getContainees()
Returns a collection of objects that are contained in this Folder object. The returned collection can include folders and any objects that implement the ContainableObject interface.

To specify the type (or types) of objects to return, use one of the forms of the getContainees method that includes a typesReturned parameter.

For Document objects, the following default properties are returned: idmDocCurVerNum, idmAddedByGroup, idmVerDocId, idmAnnotation, idmVerFileName, idmDateAdded, idmName, idmPublish, idmVWVersion, idmVerCheckoutPending, idmVerCheckinUser, idmSearch, idmCDBehaviorId,idmVerReclaimPending, idmVerPermanent, idmDocOwner, idmDocType, idmAddedByUser, idmDocProtected, idmComment, idmDateAccessed, idmId, idmVerAvailStat, idmDocCurVerDate,idmVerCreateDate, idmVerCD, idmVerId,idmFilterQuery,idmVerCsiStatus.

The returned Document properties are a subset of all the properites stored in the com.filenet.Panagon.Document fields.

For Folder objects, the following default properties are returned: idmId, idmDateAdded, idmFolderReplType, idmName, idmAddedByUser, idmComment.

The returned Folder properties are a subset of all the properites stored in the com.filenet.Panagon.Folder fields.

To return properties other than the default properties returned with a Document or Folder object, call the getContainees(typesReturned, propNames) form of this method.

Returns:
A BaseObjects collection that contains the objects contained in this Folder. If no objects are contained in this Folder object, then this method returns an empty BaseObjects collection.


getContainees

public BaseObjects getContainees(boolean includeHidden)
Returns a collection of objects that are contained in this Folder object. The returned collection can include folders and any objects that implement the ContainableObject interface.

To specify the type (or types) of objects to return, use one of the forms of the getContainees method that includes a typesReturned parameter.

For Document objects, the following default properties are returned: idmDocCurVerNum, idmAddedByGroup, idmVerDocId, idmAnnotation, idmVerFileName, idmDateAdded, idmName, idmPublish, idmVWVersion, idmVerCheckoutPending, idmVerCheckinUser, idmSearch, idmCDBehaviorId,idmVerReclaimPending, idmVerPermanent, idmDocOwner, idmDocType, idmAddedByUser, idmDocProtected, idmComment, idmDateAccessed, idmId, idmVerAvailStat, idmDocCurVerDate,idmVerCreateDate, idmVerCD, idmVerId,idmFilterQuery,idmVerCsiStatus.

The returned Document properties are a subset of all the properites stored in the com.filenet.Panagon.Document fields.

For Folder objects, the following default properties are returned: idmId, idmDateAdded, idmFolderReplType, idmName, idmAddedByUser, idmComment.

The returned Folder properties are a subset of all the properites stored in the com.filenet.Panagon.Folder fields.

To return properties other than the default properties returned with a Document or Folder object, call the getContainees(typesReturned, propNames) form of this method.

Parameters:
includeHidden - - Requires a boolean value; however, the value is ignored by the CS Java Connector.

Returns:
A BaseObjects collection that contains objects contained in this Folder. If no objects are contained in this Folder object, then this method returns an empty BaseObjects collection.


move

public void move(Folder destinationParent)
Moves this Folder object and all of its sub-folders and contents from its current parent folder to the parent folder specified by the destinationFolder parameter. The folder specified in destinationFolder must already exist. You cannot move the root folder.

After a successful call to move, the following properties are considered stale and are removed from cache for this Folder object:

The following properties are removed from cache for the target folder:

A subsequent request for any of these properties causes the CS Java Connector to retrieve fresh data from the Content Services server.

Parameters:
destinationParent - The target folder to which this Folder object is to be moved.

getParentFolder

public Folder getParentFolder()
Returns a reference to the parent folder of this Folder object.

Returns:
A Folder object that is the parent folder of this Folder object. If this Folder object is the root folder, returns null.

getUserAccess

public Permissions getUserAccess()

Not Implemented in CS Java Connector v3.0.

Retrieves the access rights (permissions) for the current user on this Folder object. (The current user is identified in the Session object.) The elements in the returned collection are the access rights assigned to the current user and to any groups to which this user belongs. If the user does not have explicit rights, this method returns only the access rights of the groups to which the user belongs.

Note that the returned Permissions collection represents basic object permissions (i.e., an object's Permissions property). To specify the type of permissions (basic object or audit) to retrieve for the current user, use getUserAccess(collectionType). To retrieve permissions for a specified user, use getUserAccess(collectionType, userId, domain).

Returns:
A Permissions collection containing the access rights for the current user on this Folder object.


getUserAccess

public Permissions getUserAccess(java.lang.String collectionType)

Not Implemented in CS Java Connector v3.0.

Retrieves the access rights (permissions)of the specified type for the current user on this Folder object. (The current user is identified in the Session object.) The elements in the returned collection are the access rights assigned to the current user and to any groups to which this user belongs. If the user does not have explicit rights, this method returns only the access rights of the groups to which the user belongs.

Specify the type of permissions (basic object or audit) to return in the collectionType parameter. If the user is not an Administrator and does not have specific privileges to access audit permissions, this method throws an InsufficientPermissionException if the specified collection type is Property.AUDIT_PERMISSIONS. This exception occurs even if the user has been granted full control access rights (Permission.LEVEL_FULL_CONTROL) to the object. To set audit permissions privileges for the user, refer to the Enable security auditing topic.

To retrieve permissions for a specified user, use the getUserAccess(collectionType, userId, domain) form of this method.

Parameters:
collectionType - A String that is the name of a property whose value is a collection of Content Services Permission objects. Use Property.PERMISSIONS for basic object permissions or Property.AUDIT_PERMISSIONS for audit permissions.

Returns:
A Permissions collection of the specified type containing the access rights for the current user on this Folder object.


getUserAccess

public Permissions getUserAccess(java.lang.String collectionType,
                                 java.lang.String userId)

Not Implemented in CS Java Connector v3.0.

Retrieves the access rights (permissions) of the specified type for the specified user on this Folder object. The elements in the returned collection are the access rights assigned to the specified user and to any groups to which this user belongs. If the user does not have explicit rights, this method returns only the access rights of the groups to which the user belongs.

Specify the type of permissions to return in the collectionType parameter. Currently, the only valid value for collectionType is the Property.PERMISSIONS constant for basic object permissions (that is, an object's Permissions property).

To retrieve permissions for the current user, call either getUserAccess() or getUserAccess(collectionType). These two methods offer equivalent functionality.

Parameters:
collectionType - A String that is the name of a property whose value is a collection of Content Services Permission objects. Currently, the only valid value is Property.PERMISSIONS (for basic object permissions). This method throws a RemoteServerException if you specify any other value.

userId - A String (whose value is a User object's Name property) that identifies the user for whom permissions are to be retrieved.

Returns:
A Permissions collection of the specified type containing the access rights for the specified user on this Folder object.


getUserAccess

public Permissions getUserAccess(java.lang.String collectionType,
                                 java.lang.String userId,
                                 java.lang.String domain)
Deprecated. Use (collectionType, userId) form of this method.

Not Implemented in CS Java Connector v3.0.


addSubFolder

public Folder addSubFolder(java.lang.String folderName,
                           java.lang.String folderClass,
                           Properties folderProps,
                           Permissions folderACLs)
Creates a folder as a subfolder of this Folder object. You must specify the subfolder's name in the folderName parameter.

Properties that are not specified that have default values in the Content Services object store take the defaults. You must pass in either a Permissions collection that contains elements for permissions you want to assign or null to inherit default permissions. Passing in an empty Permissions collection throws an exception. Note that the Permissions collection you set represents basic object permissions (i.e., an object's Permissions property).

After a successful call to addSubFolder, the following properties are considered stale and are removed from cache for this Folder object:

A subsequent request for any of these properties causes the CS Java Connector to retrieve fresh data from the Content Services server.

Parameters:
folderName - A String that specifies the name of the subfolder. The name must be unique within the parent folder; it must not be an empty string; the following characters are not allowed: \ / : * ? " < > |

folderClass - Requires a String value; however, the value is ignored by the CS Java Connector. You could simply pass a null.

folderProps - A Properties collection that specifies the properties to set for the subfolder. If empty or if some properties are not specified, properties that have default values in the Content Services object store take the defaults.

folderACLs - A Permissions collection that specifies the access permissions for the subfolder. If null, the subfolder inherits its permissions from its parent folder. Passing an empty collection throws an exception.

Returns:
A Folder object that represents the new subfolder.


addSubFolder

public Folder addSubFolder(java.lang.String folderName,
                           Properties folderProps,
                           Permissions folderACLs)
Creates a subfolder of this Folder object. You must specify the subfolder's name in the folderName parameter. Properties that are not specified that have default values in the Content Services object store take the defaults. You must pass in either a Permissions collection that contains elements for permissions you want to assign or null to inherit default permissions. Passing in an empty Permissions collection throws an exception. Note that the Permissions collection you set represents basic object permissions (i.e., an object's Permissions property).

After a successful call to addSubFolder, the following properties are considered stale and are removed from cache for this Folder object:

A subsequent request for any of these properties causes the CS Java Connector to retrieve fresh data from the Content Services server.

Parameters:
folderName - A String that specifies the name of the subfolder. The name must be unique within the parent folder; it must not be an empty string; the following characters are not allowed: \ / : * ? " < > |

folderProps - A Properties collection that specifies the properties to set for the subfolder. If empty or if some properties are not specified, properties that have default values in the Content Services object store take the defaults.

folderACLs - A Permissions collection that specifies the access permissions for the subfolder. If null, the subfolder inherits its permissions from its parent folder. Passing an empty collection throws an exception.

Returns:
A Folder object that represents the new subfolder.


delete

public void delete()
Deletes this Folder object if the user has appropriate permissions and there is no constraint upon it that makes it unable to be deleted. For example, you cannot delete the root folder.

If you delete a folder that contains subfolders, all subfolders are deleted as well, assuming security is sufficient. Other objects, such as documents, are automatically unfiled from the folder when you delete it.

After a successful call to delete, all properties for this Folder object are considered stale and are removed from cache.


getContaineesXML

public java.lang.String getContaineesXML(int[] typesReturned,
                                         java.lang.String[] propNames)
Returns a string in XML that represents a collection of objects (and their requested properties) of the specified type or types that are contained in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER.

For this version of the Content Services Java Connector, you can specify the following types in the integer array:

Specify the properties to return in the propNames array. If you specify a property and an object does not have that property, the property is ignored for that object. Therefore, if you specify several types of objects in typesReturned, and you specify properties that are specific to a certain object type in propNames, the objects are returned with their appropriate properties. Note that the containment name for an object will be included in the returned XML string if you include ContainmentName in the propNames array. If the propNames parameter is null or an empty array, this method returns all properties for the objects.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, retrieves all properties for the objects. However, if you pass in a null, you must first explicitly cast it to a String[] to avoid a compilation error.

Returns:
A String in XML that represents the objects of the specified types contained in this Folder object.


getContaineesXML

public java.lang.String getContaineesXML(int[] typesReturned,
                                         java.lang.String[] propNames,
                                         boolean includeHidden)
Returns a string in XML that represents a collection of objects (and their requested properties) of the specified type or types that are contained in this Folder object. Specify the types of objects to return in the typesReturned array using constants from the BaseObject interface. Valid object types include those for any object that implements the ContainableObject interface as well as TYPE_FOLDER.

For this version of the Content Services Java Connector, you can specify the following types in the integer array:

Specify the properties to return in the propNames array. If you specify a property and an object does not have that property, the property is ignored for that object. Therefore, if you specify several types of objects in typesReturned, and you specify properties that are specific to a certain object type in propNames, the objects are returned with their appropriate properties. Note that the containment name for an object will be included in the returned XML string if you include ContainmentName in the propNames array. If the propNames parameter is null or an empty array, this method returns all properties for the objects.

Parameters:
typesReturned - An array of type int that specifies the types of objects to return.

propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, retrieves all properties for the objects.
includeHidden - - Requires a boolean value; however, the value is ignored by the CS Java Connector.

Returns:
A String in XML that represents the objects of the specified types contained in this Folder object.


getParentFolderXML

public java.lang.String getParentFolderXML()
Returns a string in XML that represents a reference to the parent folder of this Folder object.

Returns:
A String in XML that represents the parent folder of this Folder object.

getPermissionsXML

public java.lang.String getPermissionsXML()
Retrieves a string in XML that represents the permissions for this Folder object. The user must have Read permission on the Folder object (either Permission.LEVEL_VIEW or Permission.RIGHT_READ_ACL) to retrieve the object's permissions. Note that the returned string represents basic object permissions (i.e., an object's Permissions property).

Returns:
A String in XML that represents the basic object permissions for this Folder object.

getUserAccessXML

public java.lang.String getUserAccessXML()

Not Implemented in CS Java Connector v3.0.

Retrieves a string in XML that represents the access rights (permissions) for the current user on this Folder object. (The current user is identified in the Session object.) The elements in the returned collection are the access rights assigned to the current user and to any groups to which this user belongs. If the user does not have explicit rights, this method returns only the access rights of the groups to which the user belongs.

Note that the returned string represents basic object permissions (i.e., an object's Permissions property).

Returns:
A String in XML that represents the current user's access rights for this Folder object.

changeClass

public void changeClass(java.lang.String classId,
                        Properties props,
                        Permissions perms)

Not Implemented in CS Java Connector v3.0.

Changes the class with which this Folder object is associated in the object store. The new class and the old class must have the same object type, BaseObject.TYPE_FOLDER.

Since the required properties for the two classes might differ, this method takes an optional Properties collection as one of its parameters. The collection can be empty or the parameter can be null if no changes are required. This method will throw an exception if you explicitly set the value of a contained Property object that cannot be set due to its Settability property (e.g., it is Read-only). Note that this exception will be thrown even if the new value of a property you explicitly set is the same as its old value.

This method also takes an optional Permissions collection as one of its parameters. If this parameter is null, the Folder object's security is not modified, even if the object's current security is derived from the default security for its source class. Note that this Permissions collection represents the basic object permissions for the object (i.e., the object's Permissions property). If you pass in an empty Permissions collection, all existing permissions are removed. Note that, if the permissions are modified inappropriately, it is possible to make a change that cannot be reversed by the same user.

Parameters:
classId - A String that represents the ID or the symbolic name of the class to which this object is to be changed. (The ClassDescription interface has constants for well-known class IDs.)

props - A Properties collection. The elements of the collection specify properties to change. Can be null or an empty collection if no property changes are required.

perms - A Permissions collection. The elements of the collection specify the permissions to change. Can be null if no permission changes are necessary. Passing an empty collection removes all existing permissions.


getHeadLinks

public Links getHeadLinks(java.lang.String[] propNames)

Not Implemented in CS Java Connector v3.0.

Returns a collection of Link objects for which this Folder object is the logical head of a link relationship.

Parameters:
propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, returns the Id, Name, Head, and Tail properties.

Returns:
A Links collection containing any Link objects for which this Folder object is the logical head of a link relationship.

getTailLinks

public Links getTailLinks(java.lang.String[] propNames)

Not Implemented in CS Java Connector v3.0.

Returns a collection of Link objects for which this Folder object is the logical tail of a link relationship.

Parameters:
propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, returns the Id, Name, Head, and Tail properties.

Returns:
A Links collection containing any Link objects for which this Folder object is the logical tail of a link relationship.

applySecurityTemplate

public void applySecurityTemplate(java.lang.String applyStateId)

Not Implemented in CS Java Connector v3.0.

Applies the specified security template to this Folder object. To successfully execute this method, the user must have permission to modify this Folder object's security (see the RIGHT_WRITE_ACL constant in the Permission interface).

The parameter to this method is a user-defined GUID that is managed by your application. The GUID is used to identify and locate a corresponding security template from those available in the SecurityPolicy container object assigned to this Folder object.

This method is useful for propagating a security policy change to objects that are currently using that security policy. You can use a query approach of your choice to retrieve a list of objects that are using the SecurityPolicy object, then iterate over the returned list, calling this method on each item to explicitly apply the change.

Parameters:
applyStateId - A String containing a GUID that identifies the security template you want to apply from those available in the security policy. Cannot be null.

getSubscriptions

public Subscriptions getSubscriptions(java.lang.String[] propNames)

Not Implemented in CS Java Connector v3.0.

Returns a collection of Subscription objects for which this Folder object is the subscription's target object. An object is a target object if a Subscription object's SubscriptionTarget property points to either the object or to the ClassDescription of the object (or to some superclass of the ClassDescription if it is a class subscription whose IncludeSubclassesRequested property is true).

If propNames is null or an empty array, this method retrieves an initial set of hard-coded properties. However, because this set can vary from release to release, we recommend you specify the properties your application requires in the propNames array.

Parameters:
propNames - A String array whose elements specify the symbolic names of the properties to retrieve.

Returns:
A Subscriptions collection that contains the Subscription objects associated with this Folder object.

raiseEvent

public Event raiseEvent(java.lang.String classId,
                        Properties props)

Not Implemented in CS Java Connector v3.0.

Raises a custom audit event for this Folder object and returns an Event object. The returned object represents the audit event that is recorded for this Folder object. The user must have Read permission (Permission.RIGHT_READ) on this Folder object.

You must specify the ID (or the symbolic name) for the custom event in the classId parameter. To retrieve the ID for a custom event, call the getAuditDefinitions(incInherited) method on this Folder object's ClassDescription; then call the getEventClassId method on the AuditDefinition that defines the custom event.

You must include the EventStatus property in the collection you pass in for the props parameter. Set the property's value to whatever is meaningful for your application. (For system audit events, the Content Services sets the property's value to 0 indicating a successful operation, or to an error code for failure. For a custom audit event, it is up to the client application to define and interpret the value of this property.) Properties that are not specified that have default values in the Content Engine object store take the defaults. This method will throw an exception if you explicitly set the value of a contained Property object that cannot be set due to its Settability property (e.g., it is Read-only).

Note that if auditing is disabled for the object store, this method will not throw an exception. However, the audit event will not be recorded and method calls on the returned Event object will throw a BadReferenceException.

Parameters:
classId - A String that represents the ID or the symbolic name of the custom event class. If null or if this custom event is not defined for this Folder object's class, this method throws an exception.

props - A Properties collection that specifies the properties to set for the event. The collection must include the EventStatus property, which is a required property when you create an Event object.

Returns:
An Event object that represents the audit event that is recorded for this Folder object.

getHeadLinksXML

public java.lang.String getHeadLinksXML(java.lang.String[] propNames)

Not Implemented in CS Java Connector v3.0.

Returns a string in XML that represents a collection of Link objects for which this Folder object is the logical head of a link relationship. If the propNames parameter is null or an empty array, this method returns all readily-available properties for the Link objects. (For information on which properties are not returned, If the array includes properties that do not exist for the Link objects, those properties are ignored (no exception is thrown). Note that this method never returns binary-valued properties.

This method always makes a roundtrip to the Content Services server and never uses cached properties.

Parameters:
propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, returns all readily-available properties for the Link objects.

Returns:
A String containing an XML representation of the Link objects for which this Folder object is the logical head of a link relationship. For documentation that describes the XML schema used to generate the string, refer to Schemas in the FileNet P8 Developer's Roadmap.

getTailLinksXML

public java.lang.String getTailLinksXML(java.lang.String[] propNames)

Not Implemented in CS Java Connector v3.0.

Returns a string in XML that represents a collection of Link objects for which this Folder object is the logical tail of a link relationship. If the propNames parameter is null or an empty array, this method returns all readily-available properties for the Link objects. (For information on which properties are not returned. If the array includes properties that do not exist for the Link objects, those properties are ignored (no exception is thrown). Note that this method never returns binary-valued properties.

This method always makes a roundtrip to the Content Services server and never uses cached properties.

Parameters:
propNames - A String array whose elements specify the symbolic names of the properties to retrieve. If null or an empty array, returns all readily-available properties for the Link objects.

Returns:
A String containing an XML representation of the Link objects for which this Folder object is the logical tail of a link relationship. For documentation that describes the XML schema used to generate the string, refer to Schemas in the FileNet P8 Developer's Roadmap.

getAccessMask

public int getAccessMask()

Not Implemented in CS Java Connector v3.0.

Returns an integer representing a bit mask of access rights for this Folder object. The returned value represents a collection of access rights granted on this Folder object to the current user. You can use bitwise comparisons against the access right and level constants in the Permission interface to determine the user's specific access rights. If the Foldter object has any markings applied, the mask reflects any access rights denied by the marking constraint mask. Use the returned integer to determine if the user has the appropriate access rights to perform an operation on the object.

Note that if markings are not being used, or you need to specify a particular user, you can perform a similar function by calling getUserAccess().asMask(). However, the value returned by getAccessMask() always accurately reflects the access rights granted to the user, whereas asMask() can only reflect the access rights as they apply to the Permissions collection upon which you are acting. For example, the value returned by asMask() will not reflect access rights granted or denied by assigned markings.

Returns:
An integer representing a bit mask of the assigned access rights.


FileNet Content Services
Java Connector v3.0