public interface ObjectStore
Modifier and Type | Method and Description |
---|---|
Acl |
applyAcl(StoredObject so,
Acl addAces,
Acl removeAces,
AclPropagation aclPropagation,
String principalId)
Apply a ACLs by relative adding and removing a list of ACEs to/from an object
|
Acl |
applyAcl(StoredObject so,
Acl aces,
AclPropagation aclPropagation,
String principalId)
Apply a ACLs by setting a new list of ACEs to an object
|
void |
clear()
Clear repository and remove all data.
|
Document |
createDocument(String name,
Map<String,PropertyData<?>> propMap,
String user,
Folder folder,
List<String> policies,
Acl addACEs,
Acl removeACEs)
Create a document as initial step.
|
Folder |
createFolder(String name,
Map<String,PropertyData<?>> propMap,
String user,
Folder folder,
List<String> policies,
Acl addACEs,
Acl removeACEs)
Create a folder as initial step.
|
StoredObject |
createItem(String name,
Map<String,PropertyData<?>> propMap,
String user,
Folder folder,
List<String> policies,
Acl addACEs,
Acl removeACEs)
Create an item as initial step.
|
StoredObject |
createPolicy(String name,
String policyText,
Map<String,PropertyData<?>> propMap,
String user)
Create a policy.
|
StoredObject |
createRelationship(String name,
StoredObject sourceObject,
StoredObject targetObject,
Map<String,PropertyData<?>> propMap,
String user,
Acl addACEs,
Acl removeACEs)
Create a relationship.
|
DocumentVersion |
createVersionedDocument(String name,
Map<String,PropertyData<?>> propMap,
String user,
Folder folder,
List<String> policies,
Acl addACEs,
Acl removeACEs,
ContentStream contentStream,
VersioningState versioningState)
Create a document that supports versions as initial step.
|
void |
deleteObject(String objectId,
Boolean allVersions,
String user)
Deletes an object from the store.
|
void |
deleteVersion(DocumentVersion version)
remove a version from the store (after a cancel check-out)
|
Acl |
getAcl(int aclId)
get an ACL object from an ACL id
|
List<StoredObject> |
getCheckedOutDocuments(String orderBy,
String user,
IncludeRelationships includeRelationships)
Return a list of all documents that are checked out in the repository.
|
String |
getFolderPath(String folderId)
get the path of this folder (for folder in CMIS path is unique)
|
StoredObject |
getObjectById(String folderId)
get an object by its id
|
StoredObject |
getObjectByPath(String path,
String user)
return an object by path.
|
long |
getObjectCount()
For statistics: return the number of objects contained in the system
|
List<StoredObject> |
getRelationships(String objectId,
List<String> typeIds,
RelationshipDirection direction)
Get relationships to and from an object
|
Folder |
getRootFolder()
Get the root folder of this object store
|
boolean |
isTypeInUse(String typeId)
Check if this store contains any object with the given type id
|
void |
storeVersion(DocumentVersion version)
Persist a new version in the store (created from a check-out)
|
void |
upateObject(StoredObject so)
Persist an object after modifying the properties
|
Folder getRootFolder()
StoredObject getObjectByPath(String path, String user)
path
- the path to the objectStoredObject getObjectById(String folderId)
folderId
- the id of the objectvoid deleteObject(String objectId, Boolean allVersions, String user)
objectId
- user
- allVersions
- is TRUE all version of the document are deleted, otherwise just this oneDocument createDocument(String name, Map<String,PropertyData<?>> propMap, String user, Folder folder, List<String> policies, Acl addACEs, Acl removeACEs)
name
- name of the documentpropMap
- map of propertiesuser
- the user who creates the documentfolder
- the parent folderpolicies
- list of policies to applyaddACEs
- aces that are addedremoveACEs
- aces that are removedFolder createFolder(String name, Map<String,PropertyData<?>> propMap, String user, Folder folder, List<String> policies, Acl addACEs, Acl removeACEs)
name
- name of the folderpropMap
- map of propertiesuser
- the user who creates the documentfolder
- the parent folderpolicies
- list of policies to applyaddACEs
- aces that are addedremoveACEs
- aces that are removedDocumentVersion createVersionedDocument(String name, Map<String,PropertyData<?>> propMap, String user, Folder folder, List<String> policies, Acl addACEs, Acl removeACEs, ContentStream contentStream, VersioningState versioningState)
name
- name of the document
* @param propMap
map of properitiesuser
- the user who creates the documentfolder
- the parent folderpolicies
- list of policies to applyaddACEs
- aces that are addedremoveACEs
- aces that are removedStoredObject createItem(String name, Map<String,PropertyData<?>> propMap, String user, Folder folder, List<String> policies, Acl addACEs, Acl removeACEs)
name
- name of the documentpropMap
- map of propertiesuser
- the user who creates the documentfolder
- the parent folderpolicies
- list of policies to applyaddACEs
- aces that are addedremoveACEs
- aces that are removedStoredObject createPolicy(String name, String policyText, Map<String,PropertyData<?>> propMap, String user)
name
- name of the documentpolicyText
- policy text to apply to this policypropMap
- map of propertiesuser
- the user who creates the documentvoid storeVersion(DocumentVersion version)
version
- void deleteVersion(DocumentVersion version)
version
- version to be deletedvoid upateObject(StoredObject so)
so
- object to be updatedString getFolderPath(String folderId)
folderId
- id of foldervoid clear()
long getObjectCount()
StoredObject createRelationship(String name, StoredObject sourceObject, StoredObject targetObject, Map<String,PropertyData<?>> propMap, String user, Acl addACEs, Acl removeACEs)
sourceObject
- source of the relationshiptargetObject
- target of the relationshippropMap
- map of properitiesuser
- the user who creates the documentfolder
- the parent folderaddACEs
- aces that are addedremoveACEs
- aces that are removedList<StoredObject> getCheckedOutDocuments(String orderBy, String user, IncludeRelationships includeRelationships)
orderBy
- orderBy specification according to CMIS spec.user
- user id of user callingincludeRelationships
- if true include all relationships in the responseAcl applyAcl(StoredObject so, Acl addAces, Acl removeAces, AclPropagation aclPropagation, String principalId)
so
- object where ACLs are appliedaddAces
- list of ACEs to be addedremoveAces
- list of ACEs to be removedaclPropagation
- enum value how to propagate ACLs to child objectsAcl applyAcl(StoredObject so, Acl aces, AclPropagation aclPropagation, String principalId)
so
- object where ACLs are appliedaces
- list of ACEs to be appliedaclPropagation
- enum value how to propagate ACLs to child objectsboolean isTypeInUse(String typeId)
typeId
- id of type definition to checkList<StoredObject> getRelationships(String objectId, List<String> typeIds, RelationshipDirection direction)
objectId
- id of object to get relationships withsubTypeIds
- list of all types to be includedrelationshipDirection
- direction of relationshipAcl getAcl(int aclId)
aclId
- id of ACLCopyright © 2009-2013 The Apache Software Foundation. All Rights Reserved.