|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ResourceRepository
This interface is used for managing resources within the Repository.
Method Summary | |
---|---|
void |
copyResource(java.lang.String sourceResourcePath,
java.lang.String targetResourceCollectionPath,
short depth)
Copies the resource at sourceResourcePath into the ResourceCollection
at targetResourceCollectionPath . |
void |
createPendingRelationship(java.lang.String sourceResourceUri,
java.lang.String targetResourcePath,
int relationshipType)
Creates a PendingRelation of type relationshipType between the source and target resources. |
void |
createRelationship(java.lang.String sourceResourceUri,
java.lang.String targetResourceUri,
int relationshipType,
boolean trackHead)
Creates a Relation of type relationshipType between the source and target resources. |
void |
deleteResource(java.lang.String resourceUri)
Permanently removes the Resource identified by resourceUri from the repository. |
void |
deleteResources(java.lang.String[] resourceUris)
Permanently removes the Resource objects identified by resourceUris from the repository. |
int |
getCount(java.lang.String resourceUri,
int relationshipType,
Query query,
java.lang.String appFilterName)
Retrieves a number of resources related to the resource identified by resourceUri by a relation
of type relationshipType and which also match the supplied criteria found in
the Query object. |
java.util.List |
getHistory(java.lang.String resourceUri)
Retrieves all versions of the logical resource identified by the resourceUri . |
RepositoryImplementationType |
getImplementationType()
Describes the backing Repository implementation. |
java.util.List |
getLocks(java.lang.String resourceUri)
Retrieves a java.util.List containing all Lock objects
on a specific resource identified by the given
resourceUri . |
java.util.List |
getRelated(java.lang.String resourceUri,
boolean isSource,
int relationshipType)
Retrieves a java.util.List containing all resources related to a specific resource
by relation instances of type relationshipType . |
java.util.List |
getRelated(java.lang.String resourceUri,
boolean isSource,
int[] relationshipTypes)
Retrieves a java.util.List containing all resources related to a specific resource by relation instances of
types contained in relationshipTypes . |
java.util.List |
getRelated(java.lang.String resourceUri,
boolean isSource,
int[] relationshipTypes,
boolean returnDeprecatedResources,
boolean isHead)
Retrieves a java.util.List containing all resources related to a specific resource by relation instances of
types contained in relationshipTypes . |
java.util.List |
getRelated(java.lang.String resourceUri,
boolean isSource,
int relationshipType,
boolean returnDeprecatedResources,
boolean isHead)
Retrieves a java.util.List containing all resources related to a specific resource
by relation instances of type relationshipType . |
java.util.List |
listMembers(java.lang.String resourceCollectionUri)
Retrieves the contents of the ResourceCollection . |
java.util.List |
listMembersWithoutContent(java.lang.String resourceCollectionUri)
this method is for performance improvement for those methods who dont want to retrive TLO contents |
java.lang.String |
lockResource(java.lang.String resourceUri,
short lockScope,
short lockDepth)
Locks the logical Resource identified by resourceUri . |
java.lang.String |
lockResource(java.lang.String resourceUri,
short lockScope,
short lockDepth,
int expireSecondsFromNow)
Locks the logical Resource identified by the resourceUri , and
sets an expiration date on the lock. |
void |
moveResource(java.lang.String sourceResourcePath,
java.lang.String targetResourceCollectionPath)
Moves all versions of the logical resource at sourceResourcePath to targetResourceCollectionPath . |
AccessControlList |
readAccessControlList(java.lang.String resourceUri)
Reads an access control list for the resource identified by resourceUri . |
ResourceProperty[][] |
readProperties(java.lang.String[] resourceUris,
ResourceProperty[] propertyNames)
Retrieves an array of property instances for the requested properties. |
Resource |
readResource(java.lang.String resourceUri)
Retrieves the Resource identified by resourceUri from the Repository. |
Document |
readResourceContent(java.lang.String resourceUri)
Retrieves the content of the Resource object
identified by resourceUri from the Repository. |
java.util.List |
readResources(java.lang.String[] resourceUris)
Retrieves the Resource objects identified by resourceUris from the Repository. |
java.util.List |
readResourcesWithoutContent(java.lang.String[] resourceUris)
Retrieves the Resource objects identified by resourceUris from the Repository
without resource contents |
Resource |
readResourceWithoutContent(java.lang.String resourceUri)
Retrieves the Resource identified by resourceUri from the Repository. |
void |
registerListener(ResourceRepositoryListenerEvent event,
java.lang.String listenerName,
ResourceRepositoryListener listener)
Registers a listener to get notified about specified events in the Repository |
void |
removeProperties(java.lang.String resourceUri,
ResourceProperty[] properties,
boolean revMajorVersion)
Removes properties from a resource and creates a new version from the result. |
void |
removeRelationship(java.lang.String sourceResourceUri,
java.lang.String targetResourceUri,
int relationshipType)
Removes a Relation of type relationshipType
between the source and target resources. |
boolean |
resourceExists(java.lang.String resourceUri)
Determines whether a Resource is identified by
resourceUri in the Repository. |
boolean[] |
resourcesExist(java.lang.String[] resourceUris)
Determines whether Resource objects
identified by resourceUris exist in the Repository. |
java.util.List |
searchProperties(java.lang.String basePath,
Query queryString,
int depth,
int start,
int maxResults,
SortOrder sortOrder)
Executes a properties search against the resources contained within the Repository. |
java.util.List |
searchRelated(java.lang.String resourceUri,
int relationshipType,
int depth,
Query query,
int start,
int maxResults,
SortOrder sortOrder)
Retrieves a list of resources related to the resource identified by resourceUri by a relation
of type relationshipType and which also match the supplied criteria found in
the Query object. |
java.util.List |
searchRelatedFilter(java.lang.String resourceUri,
int relationshipType,
int depth,
Query query,
int start,
int maxResults,
SortOrder sortOrder,
java.lang.String appFilterName)
Retrieves a list of resources related to the resource identified by resourceUri by a relation
of type relationshipType and which also match the supplied criteria found in
the Query object. |
void |
selectVersion(java.lang.String sourceResourceUri,
java.lang.String targetResourceUri,
int relationshipType,
java.lang.String newVersionUri,
boolean applyToSource,
boolean trackHead)
Changes the version of a resource involved in a relationship to the version identified by newVersionUri . |
java.lang.String |
unlockResource(java.lang.String resourceUri)
Unlocks the locked resources identified by the resourceUri . |
void |
unregisterListener(ResourceRepositoryListenerEvent event,
java.lang.String listenerName)
Deletes a listener already registered to get notified about specified events in the Repository |
void |
updateCustomStatus(java.lang.String resourceUri,
java.lang.String customStatus)
Updates the custom status of a resource. |
void |
updateDeploymentStatus(java.lang.String resourceUri,
int deploymentStatus)
Updates the deployment status of a resource. |
void |
updateObjectStatus(java.lang.String resourceUri,
int objectStatus)
Updates the object status of a resource. |
void |
updateProperties(java.lang.String[] resourceUris,
ResourceProperty[] properties)
Adds and updates the properties of the resources. |
void |
updateProperties(java.lang.String resourceUri,
ResourceProperty[] properties)
Adds and updates the properties of a resource. |
Resource |
updateResource(java.lang.String resourceUri,
Resource resource,
boolean revMajorVersion)
Updates the resource identified by resourceUri with the data in
resource . |
Resource |
updateResourceWithId(java.lang.String resourceUri,
java.lang.String resourceVersionId,
boolean revMajorVersion)
The purpose of this method is to allow a resource to be updated using content from a previous revision of the same logical resource. |
void |
writeAccessControlList(java.lang.String resourceUri,
AccessControlList accessControlList,
boolean propagate)
Sets or updates the access control list (ACL) contained in accessControlList on the resources
identified by the resourceUri . |
void |
writeAccessControlList(java.lang.String resourceUri,
AccessControlList accessControlList,
short propagationMode)
Sets or updates the access control list (ACL) contained in accessControlList on the resources
identified by the resourceUri . |
Resource |
writeResource(java.lang.String parentResourcePath,
Resource resource)
Writes a new resource into the Repository. |
Method Detail |
---|
void copyResource(java.lang.String sourceResourcePath, java.lang.String targetResourceCollectionPath, short depth) throws RepositoryException
sourceResourcePath
into the ResourceCollection
at targetResourceCollectionPath
. If sourceResourcePath
is a
ResourceCollection
, the depth
parameter indicates whether the operation is recursive,
and if so, to what degree. Only the head versions of Resource
objects are copied.
Overwriting does not occur.
Pre-conditions:
targetResourceCollectionPath
must exist.targetResourceCollectionPath
must identify a ResourceCollection
.targetResourceCollectionPath + "/" + source.getName()
must not exist.depth
must be one of Resource.DEPTH_ZERO
,
ResourceCollection.DEPTH_ONE
, or
ResourceCollection.DEPTH_INFINITE
.Post-conditions:
Resource
objects will be created with new Lid
and Id
objects.ResourceCollection
objects will also be assigned new Lid
and Id
objects.1.0
.
sourceResourcePath
- A path-based identifier that identifies a Resource
.targetResourceCollectionPath
- A path-based identifier that identifies
the ResourceCollection
where the resource identified by sourceResourcePath
will be copied.depth
- One of Resource.DEPTH_ZERO
, ResourceCollection.DEPTH_ONE
, or
ResourceCollection.DEPTH_INFINITE
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | depth is not one of the allowed values |
ALC-REP-015-000 | A resource exists at targetResourceCollectionPath + "/" + source.getName() |
ALC-REP-016-000 | The resource collection identified by targetResourceCollectionPath is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource collection identified by targetResourceCollectionPath is locked |
ALC-REP-018-000 | The resource identified by sourceResourcePath or targetResourceCollectionPath does not exist or is not accessible |
ALC-REP-050-000 | sourceResourcePath is not a path-based identifier |
ALC-REP-054-000 | depth is not one of the allowed values |
ALC-REP-055-000 | targetResourceCollectionPath does not identify a ResourceCollection |
void createRelationship(java.lang.String sourceResourceUri, java.lang.String targetResourceUri, int relationshipType, boolean trackHead) throws RepositoryException
Relation
of type relationshipType
between the source and target resources.
Relationships of type Relation.TYPE_MEMBER_OF
must be created with writeResource()
.
When the logical resource identified by targetResourceUri
is updated:
trackHead
is true
, the targetResourceUri
attribute will be automatically updated to the
Id
-based identifier of the new head resource.trackHead
is false
, the targetResourceUri
attribute will remain unchanged, and will continue
to reference the same version that was referenced when the Relation
was created.Pre-conditions:
Relation
of type relationshipType
must not exist between sourceResourceUri
and
targetResourceUri
.relationshipType
is not equal to Relation.TYPE_MEMBER_OF
.Post-conditions:
Relation
of type relationshipType
exists between sourceResourceUri
and targetResourceUri
.
sourceResourceUri
- The source of the relationship.targetResourceUri
- The target of the relationship.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.trackHead
- Determines whether the new relationship should always refer to the latest version of the
resource identified by targetResourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by sourceResourceUri or targetResourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by sourceResourceUri or targetResourceUri is locked |
ALC-REP-018-000 | The resource identified by sourceResourceUri or targetResourceUri does not exist or is not accessible |
ALC-REP-013-000 | relationshipType is less than one |
ALC-REP-024-000 | relationshipType is equal to Relation.TYPE_MEMBER_OF |
ALC-REP-030-000 | relationshipType is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
void createPendingRelationship(java.lang.String sourceResourceUri, java.lang.String targetResourcePath, int relationshipType) throws RepositoryException
PendingRelation
of type relationshipType
between the source and target resources.
Pre-conditions:
sourceResourceUri
must exist.targetResourcePath
must not exist.PendingRelation
of type relationshipType
must not exist between sourceResourceUri
and
targetResourcePath
.relationshipType
is not equal to Relation.TYPE_MEMBER_OF
.Post-conditions:
PendingRelation
of type relationshipType
exists between source resource sourceResourceUri
and non-existent target resource targetResourcePath
.
sourceResourceUri
- The source of the relationship.targetResourcePath
- The target of the relationship.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by sourceResourceUri is locked by another user |
ALC-REP-018-000 | The resource identified by sourceResourceUri does not exist or is not accessible |
ALC-REP-013-000 | relationshipType is less than one |
ALC-REP-024-000 | relationshipType is equal to Relation.TYPE_MEMBER_OF |
ALC-REP-030-000 | relationshipType is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
void deleteResource(java.lang.String resourceUri) throws RepositoryException
Resource
identified by resourceUri
from the repository. Deleting a
ResourceCollection
also deletes its members. If a head version is deleted, the previous
version becomes the head version. If a deleted version was the active version, the head version
becomes the active version.
Post-conditions:
resourceUri
are permanently
removed from the repository.resourceUri
is permanently
removed from the repository only if it is no longer referenced by any other versions of
any logical resource.
resourceUri
- The Resource
to be deleted.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-051-000 | resourceUri is a system path of / |
void deleteResources(java.lang.String[] resourceUris) throws RepositoryException
Resource
objects identified by resourceUris
from the repository.
Deleting a ResourceCollection
also deletes its members. If the head version is deleted, the
previous version becomes the head version.
Duplicate URIs are silently ignored. To improve performance, clients should avoid submitting URIs that are known duplicates.
URIs that specify a subset of other URIs provided in the same request will be silently ignored.
For example, a request to delete URIs {/a, /a/b}
will succeed without warnings about /a/b
being
a subfolder of /a
. To improve performance, clients should avoid submitting URIs that are known to be subsets of other URIs.
Post-conditions:
resourceUris
are permanently
removed from the repository.resourceUris
are permanently
removed from the repository only if they are no longer referenced by any other versions.
resourceUris
- An array of Resource
objects to be deleted.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | A resource identified by one of the elements of resourceUris is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. A resource identified by one of the elements of resourceUris is locked |
ALC-REP-018-000 | A resource identified by one of the elements of resourceUris does not exist or is not accessible |
ALC-REP-051-000 | A resource identified by one of the elements of resourceUris is a system path of / |
java.util.List getHistory(java.lang.String resourceUri) throws RepositoryException
resourceUri
.
Clients should use Lid
-based or path-based identifiers for best performance. If a version of the
resource identified by resourceUri
is not accessible, the version is silently
excluded from the results.
resourceUri
- A Resource
for which to retrieve its version history.
java.util.List
of Resource
instances, each representing a version of the logical resource.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The version of the resource identified by resourceUri does not exist or is not accessible |
RepositoryImplementationType getImplementationType() throws RepositoryException
RepositoryException
java.util.List getLocks(java.lang.String resourceUri) throws RepositoryException
java.util.List
containing all Lock
objects
on a specific resource identified by the given
resourceUri
.
resourceUri
- A Resource
for which to retrieve locks.
java.util.List
of Lock
instances on the Resource
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
java.util.List getRelated(java.lang.String resourceUri, boolean isSource, int relationshipType) throws RepositoryException
java.util.List
containing all resources related to a specific resource
by relation instances of type relationshipType
. If isSource
is true
,
this method returns all the Resource
objects that are targets of relations
of type relationshipType
and for which resourceUri
is the source.
If isSource
is false
, this method returns all the Resource
objects that
are sources of relations of type relationshipType
and for which
resourceUri
is the target.
Pre-conditions:
relationshipType
must be positive and not within the reserved values list.
resourceUri
- The Resource
for which to get related resources.isSource
- true
if the resourceUri
is the source of the relationship and
therefore the target resources should be returned. Otherwise, the resourceUri
is
the target of the relation and source resources should be returned.relationshipType
- The type of relationship, chosen among the
Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | relationshipType is less than one |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
java.util.List getRelated(java.lang.String resourceUri, boolean isSource, int[] relationshipTypes) throws RepositoryException
java.util.List
containing all resources related to a specific resource by relation instances of
types contained in relationshipTypes
. If isSource
is true
,
this method returns all the Resource
objects that are targets of relations
of type relationshipTypes
and for which resourceUri
is the source.
If isSource
is false
, this method returns all the Resource
objects that
are sources of relations of type relationshipTypes
and for which
resourceUri
is the target.
Pre-conditions:
Each element of relationshipTypes
must be positive.
resourceUri
- The Resource
for which to get related resources.isSource
- true
if the resourceUri
is the source of the relationship and
therefore the target resources should be returned. Otherwise, the resourceUri
is
the target of the relation and source resources should be returned.relationshipTypes
- The types of relationships to return, chosen among the
Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | An element of relationshipTypes is less than one |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | An element of relationshipTypes is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
java.util.List getRelated(java.lang.String resourceUri, boolean isSource, int relationshipType, boolean returnDeprecatedResources, boolean isHead) throws RepositoryException
java.util.List
containing all resources related to a specific resource
by relation instances of type relationshipType
. If isSource
is true
,
this method returns all the Resource
objects that are targets of relations
of type relationshipType
and for which resourceUri
is the source.
If isSource
is false
, this method returns all the Resource
objects that
are sources of relations of type relationshipType
and for which
resourceUri
is the target.
Pre-conditions:
relationshipType
must be positive and not within the reserved values list.
resourceUri
- The Resource
for which to get related resources.isSource
- true
if the resourceUri
is the source of the relationship and
therefore the target resources should be returned. Otherwise, the resourceUri
is
the target of the relation and source resources should be returned.relationshipType
- The type of relationship, chosen among the
Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.returnDeprecatedResources
- If returnDeprecatedResources
is false
then only resources
that are not deprecated will be returned. If returnDeprecatedResources
is true all Resources will be returned.isHead
- If isHead
is false
then all related resources will be returned. If isHead
is true
only related Resources which are the head version will be returned.
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | relationshipType is less than one |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
java.util.List getRelated(java.lang.String resourceUri, boolean isSource, int[] relationshipTypes, boolean returnDeprecatedResources, boolean isHead) throws RepositoryException
java.util.List
containing all resources related to a specific resource by relation instances of
types contained in relationshipTypes
. If isSource
is true
,
this method returns all the Resource
objects that are targets of relations
of type relationshipTypes
and for which resourceUri
is the source.
If isSource
is false
, this method returns all the Resource
objects that
are sources of relations of type relationshipTypes
and for which
resourceUri
is the target.
Pre-conditions:
Each element of relationshipTypes
must be positive.
resourceUri
- The Resource
for which to get related resources.isSource
- true
if the resourceUri
is the source of the relationship and
therefore the target resources should be returned. Otherwise, the resourceUri
is
the target of the relation and source resources should be returned.relationshipTypes
- The types of relationships to return, chosen among the
Relation
.TYPE_*
constants,
or a user-defined value greater or equal to 1024
.returnDeprecatedResources
- If returnDeprecatedResources
is false
then only resources that are not deprecated will be returned. If returnDeprecatedResources
is true
all Resources will be returned.isHead
- If isHead
is false
then all related resources will be returned. If isHead
is true
only related Resources which are the head version will be returned.
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | An element of relationshipTypes is less than one |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | An element of relationshipTypes is a reserved value. For example, it is positive, not a constant, and is less than 1024 . |
java.util.List listMembers(java.lang.String resourceCollectionUri) throws RepositoryException
ResourceCollection
.
Internal members are immediate children of
a resource collection. If you call this method for anything other than a resource collection, no results are returned.
resourceCollectionUri
- The resource collection identifier.
java.util.List
of Resource
objects that are the source of a
Relation
of type
Relation.TYPE_MEMBER_OF
and have
resourceCollectionUri
as the target.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The version of the resource identified by resourceCollectionUri does not exist or is not accessible |
java.util.List listMembersWithoutContent(java.lang.String resourceCollectionUri) throws RepositoryException
resourceCollectionUri
- The resource collection identifier.
java.util.List
of Resource
objects that are the source of a
Relation
of type
Relation.TYPE_MEMBER_OF
and have
resourceCollectionUri
as the target.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The version of the resource identified by resourceCollectionUri does not exist or is not accessible |
java.lang.String lockResource(java.lang.String resourceUri, short lockScope, short lockDepth) throws RepositoryException
Resource
identified by resourceUri
.
Id
-based identifiers resolve to logical resources.
The lockDepth
parameter only applies when resourceUri
is
a ResourceCollection
. In this case,
Lock.DEPTH_ZERO
locks only the collection,
Lock.DEPTH_ONE
locks the collection and its internal
members, and Lock.DEPTH_INFINITE
locks the collection and all members.
Pre-conditions:
lockScope
is either Lock.SCOPE_EXCLUSIVE
or Lock.SCOPE_SHARED
.lockDepth
is one of Lock.DEPTH_ZERO
,
Lock.DEPTH_ONE
, or
Lock.DEPTH_INFINITE
.Post-conditions:
The resource identified by resourceUri
is write-locked with a lock scope
equal to lockScope
.
resourceUri
- The Resource
identifier.lockScope
- Either Lock.SCOPE_EXCLUSIVE
or Lock.SCOPE_SHARED
.lockDepth
- One of Lock.DEPTH_ZERO
,
Lock.DEPTH_ONE
, or
Lock.DEPTH_INFINITE
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The version of the resource identified by resourceUri does not exist or is not accessible |
ALC-REP-031-000 | lockScope is not an accepted value |
ALC-REP-032-000 | lockDepth is not an accepted value |
java.lang.String lockResource(java.lang.String resourceUri, short lockScope, short lockDepth, int expireSecondsFromNow) throws RepositoryException
Resource
identified by the resourceUri
, and
sets an expiration date on the lock.
Id
-based identifiers resolve to logical resources. The returned lock token is
automatically added to the set of lock tokens inside the delegate.
The lockDepth
parameter only applies when resourceUri
is
a ResourceCollection
. In this case,
Lock.DEPTH_ZERO
locks only the collection,
Lock.DEPTH_ONE
locks the collection and its internal
members, and Lock.DEPTH_INFINITE
locks the collection and all members.
Pre-conditions:
lockScope
is either Lock.SCOPE_EXCLUSIVE
or Lock.SCOPE_SHARED
.lockDepth
is one of Lock.DEPTH_ZERO
,
Lock.DEPTH_ONE
, or
Lock.DEPTH_INFINITE
.expireSecondsFromNow
is positive.Post-conditions:
The resource identified by resourceUri
is write-locked with a lock scope
equal to lockScope
and will expire in expireSecondsFromNow
.
resourceUri
- The Resource
identifier.lockScope
- Either Lock.SCOPE_EXCLUSIVE
or Lock.SCOPE_SHARED
.lockDepth
- One of Lock.DEPTH_ZERO
,
Lock.DEPTH_ONE
, or
Lock.DEPTH_INFINITE
.expireSecondsFromNow
- A positive value indicating the number of seconds
in which this lock will expire.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | expireSecondsFromNow is not a positive value |
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The version of the resource identified by resourceUri does not exist or is not accessible |
ALC-REP-031-000 | lockScope is not an accepted value |
ALC-REP-032-000 | lockDepth is not an accepted value |
ALC-REP-042-000 | resourceUri is already share-locked, and cannot add an exclusive lock |
ALC-REP-043-000 | resourceUri is already exclusively locked, and cannot add a shared lock |
void moveResource(java.lang.String sourceResourcePath, java.lang.String targetResourceCollectionPath) throws RepositoryException
sourceResourcePath
to targetResourceCollectionPath
.
A move operation should be approached with as much caution as a delete operation, because
references embedded in user content will break once the resource is moved.
The operation is atomic; if a member of the targetResourcePath
cannot be moved, the operation
fails. This is in contrast with sourceResourcePath
as possible, and return a multi-status
response indicating the failures that occurred.
Pre-conditions:
targetResourceCollectionPath
must exist.targetResourceCollectionPath
must identify a ResourceCollection
.targetResourceCollectionPath + "/" + source.getName()
must not exist.Post-conditions:
Lid
and
Id
objects.
sourceResourcePath
- The resource to move.targetResourceCollectionPath
- The destination ResourceCollection
in which the source resource will be contained at the end of the operation.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-015-000 | A resource exists at path targetResourceCollectionPath + "/" + source.getName() |
ALC-REP-016-000 | The resource identified by sourceResourcePath or targetResourceCollectionPath is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by sourceResourcePath or targetResourceCollectionPath is locked |
ALC-REP-018-000 | The resource identified by sourceResourcePath or targetResourceCollectionPath does not exist or is not accessible |
ALC-REP-050-000 | sourceResourcePath or targetResourceCollectionPath is not a path-based identifier |
AccessControlList readAccessControlList(java.lang.String resourceUri) throws RepositoryException
resourceUri
.
resourceUri
- The Resource
for which to retrieve its access control list.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ResourceProperty[][] readProperties(java.lang.String[] resourceUris, ResourceProperty[] propertyNames) throws RepositoryException
propertyNames
. The absence of a
property on a resource is signaled in the results by a null
object at the non-existent
property's index.
Pre-conditions:
propertyNames
and its elements must not be null
.ResourceProperty
in propertyNames
cannot be null
.Post-conditions:
Property arrays are returned in the order in which their resourceUri
counterparts
were submitted.
resourceUris
- An array of resource identifiers for which to return properties.propertyNames
- ResourceProperty
instances having names and namespaces that identify which properties to return.
ResourceProperty
instances. The first dimension contains a
ResourceProperty
[]
for each element of resourceUris
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | A ResourceProperty in propertyNames has a null or empty name or namespace. |
ALC-REP-018-000 | A resource identified by an element of resourceUris does not exist or is not accessible |
Resource readResource(java.lang.String resourceUri) throws RepositoryException
Resource
identified by resourceUri
from the Repository.
resourceUri
- The resource to be retrieved.
Resource
instance identified by resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
Resource readResourceWithoutContent(java.lang.String resourceUri) throws RepositoryException
Resource
identified by resourceUri
from the Repository.
without resource content
resourceUri
- The resource to be retrieved.
Resource
instance identified by resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
java.util.List readResources(java.lang.String[] resourceUris) throws RepositoryException
Resource
objects identified by resourceUris
from the Repository.
resourceUris
- The resources to be retrieved.
java.util.List
of Resource
instances identified by resourceUris
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | A resource identified by an element of resourceUris does not exist or is not accessible |
java.util.List readResourcesWithoutContent(java.lang.String[] resourceUris) throws RepositoryException
Resource
objects identified by resourceUris
from the Repository
without resource contents
resourceUris
- The resources to be retrieved.
java.util.List
of Resource
instances identified by resourceUris
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | A resource identified by an element of resourceUris does not exist or is not accessible |
boolean[] resourcesExist(java.lang.String[] resourceUris) throws RepositoryException
Resource
objects
identified by resourceUris
exist in the Repository.
resourceUris
- The resources to check.
boolean
values representing whether a
Resource
is identified by each item URI in
resourceUris
.
RepositoryException
boolean resourceExists(java.lang.String resourceUri) throws RepositoryException
Resource
is identified by
resourceUri
in the Repository.
resourceUri
- The resource to be checked.
true
if a Resource
is identified by resourceUri
.
RepositoryException
Document readResourceContent(java.lang.String resourceUri) throws RepositoryException
Resource
object
identified by resourceUri
from the Repository.
This method may return null
, in which case the Resource
may still have content associated with it, but is stored externally.
See Resource.getContent()
and
ResourceContent.getContentUri()
.
resourceUri
- The resource for which the content will be returned.
Document
object representing the resource's content.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
void removeProperties(java.lang.String resourceUri, ResourceProperty[] properties, boolean revMajorVersion) throws RepositoryException
updateResource()
. Reserved namespace properties that can be assigned null
values,
such as a resource description, may be supplied as arguments to this method,
but will only be set to null
and will not actually be removed as dynamic properties would.
Post-conditions:
A new version of the resource is created without the properties specified in
propertyNames
.
resourceUri
- The resource from which to remove properties.properties
- The properties to remove. Only the namespace and name are required; the value is
ignored.revMajorVersion
- true
to increment the major version number and reset the minor version
number to zero; false
to increment the minor version number and to leave the major
version number unchanged.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-019-000 | A property cannot be removed. For example, the identifier attribute is immutable. |
ALC-REP-021-000 | Pre-condition 1 of updateResource() fails |
ALC-REP-020-000 | Pre-condition 2 of updateResource() fails |
ALC-REP-022-000 | The post-condition of updateResource() fails |
void removeRelationship(java.lang.String sourceResourceUri, java.lang.String targetResourceUri, int relationshipType) throws RepositoryException
Relation
of type relationshipType
between the source and target resources. It is not
an error to remove a non-existent relationship, since the post-condition is satisfied.
Pre-conditions:
relationshipType
is one of the Relation
.TYPE_*
constants, or a user-defined type with a value greater than or equal to 1024
.
Post-conditions:
A Relation
of type relationshipType
no longer exists
between sourceResourceUri
and targetResourceUri
.
sourceResourceUri
- The source of the relationship.targetResourceUri
- The target of the relationship.relationshipType
- The type of relationship, chosen from the
Relation
.TYPE_*
constants,
or a user-defined type with a value greater than or equal to 1024
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by sourceResourceUri or targetResourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by sourceResourceUri or targetResourceUri is locked |
ALC-REP-018-000 | The resource identified by sourceResourceUri or targetResourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is reserved. For example, it is positive, not a constant and less than 1024 . |
ALC-REP-013-000 | relationshipType is less than one |
java.util.List searchProperties(java.lang.String basePath, Query queryString, int depth, int start, int maxResults, SortOrder sortOrder) throws RepositoryException
Query
object filter are returned.
Infinite-depth searches recursively traverse relations from target to source,
effectively searching an entire resource collection's members.
This method supports results paging; the start
parameter is zero-based.
basePath
- The base path from which to execute the properties search.queryString
- An instance of Query
consisting
of logically related conditions on which to base the search.depth
- The depth of the search. Its possible values are
ResourceCollection.DEPTH_ONE
(to search the base path only) or
ResourceCollection.DEPTH_INFINITE
(to search the base path and all folders).start
- Indicates the first row from which to select the unpaged result set.maxResults
- The maximum number of resources returned per page, starting at index start
of the entire result set.sortOrder
- An instance of SortOrder
that defines the sort order of the unpaged result set.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | start is less than zero,
maxResults is less than one, or
depth is not equal to
ResourceCollection.DEPTH_ONE or
ResourceCollection.DEPTH_INFINITE |
ALC-REP-018-000 | The resource identified resourceUri does not exist or is not accessible |
Query
,
SortOrder
java.util.List searchRelated(java.lang.String resourceUri, int relationshipType, int depth, Query query, int start, int maxResults, SortOrder sortOrder) throws RepositoryException
resourceUri
by a relation
of type relationshipType
and which also match the supplied criteria found in
the Query
object.
The resource identified by resourceUri
is taken to be the target of the relationships,
and infinite-depth searches recursively traverse relations from target to source.
The implementation supports results paging; both the start
and maxResults
parameters are zero-based.
resourceUri
- The Resource
for which to retrieve related resources.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater than or equal to 1024
.depth
- The depth of the search. Its possible values are
ResourceCollection.DEPTH_ONE
(search the base path only) or
ResourceCollection.DEPTH_INFINITE
(search the base path and all subfolders).query
- An instance of Query
describing a Repository query.start
- Indicates the first row to select from the unpaged result set.maxResults
- The maximum number of resources returned per page, starting at index start
of the entire result set.sortOrder
- Format and type TBD
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | start is less than zero,
maxResults is less than one, or
relationshipType is less than one |
ALC-REP-018-000 | The resource identified resourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is reserved. For example, it is positive, not a constant and less than 1024 . |
Query
,
SortOrder
void selectVersion(java.lang.String sourceResourceUri, java.lang.String targetResourceUri, int relationshipType, java.lang.String newVersionUri, boolean applyToSource, boolean trackHead) throws RepositoryException
newVersionUri
. It is not an error to reselect the same target, as the post-condition is still
satisfied.
Pre-conditions:
relationshipType
must be positive.Post-conditions:
The target object attribute of the existing relation object between source and target resources is modified to point to the new target resource.
sourceResourceUri
- Identifies the Resource
that is the source of the relationship.targetResourceUri
- Identifies the Resource
that is the target of the relationship.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater than or equal to 1024
.newVersionUri
- Identifies the version of the Resource
that is to become the new source
or target of the relationship. The applyToSource
parameter determines the attribute (source or
target) to which the new URI is applied.applyToSource
- If true
, the newVersionUri
is applied to the source of the relationship.
Otherwise the resourceUri
is applied to the target of the relation.trackHead
- If true
, the relationship will automatically track new versions
of the target Resource
. If false
, the relationship will not automatically change
when the target Resource
is updated.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | relationshipType is less than one |
ALC-REP-016-000 | The resource identified by sourceResourceUri or targetResourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by sourceResourceUri or targetResourceUri is locked |
ALC-REP-018-000 | The resource identified by sourceResourceUri or targetResourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is reserved. For example, it is positive, not a constant and less than 1024 . |
ALC-REP-040-000 | The relationship does not exist |
ALC-REP-044-000 |
newResourceUri is not a version of sourceResourceUri
(if applyToSource is true ), or
newResourceUri is not a version of targetResourceUri
(if applyToSource is false ) |
java.lang.String unlockResource(java.lang.String resourceUri) throws RepositoryException
resourceUri
.
Post-conditions:
If the user has system write permission, all locks on the resource are removed.
resourceUri
- The resource to unlock.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
void updateCustomStatus(java.lang.String resourceUri, java.lang.String customStatus) throws RepositoryException
Pre-conditions:
customStatus
may be null
.
Post-conditions:
customStatus
is updated on the version identified by resourceUri
.
resourceUri
- The resource to update.customStatus
- The new custom status to set.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
void updateDeploymentStatus(java.lang.String resourceUri, int deploymentStatus) throws RepositoryException
Post-conditions:
deploymentStatus
is updated on the version identified by
resourceUri
.
resourceUri
- The resource to update.deploymentStatus
- The new deployment status to set.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | deploymentStatus is less than one |
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | deploymentStatus is reserved. For example, it is positive, not a constant and less than 1024 . |
void updateObjectStatus(java.lang.String resourceUri, int objectStatus) throws RepositoryException
Pre-conditions:
The objectStatus
parameter's lifecycle must be respected.
Post-conditions:
objectStatus
is updated on the version identified by resourceUri
.
resourceUri
- The resource to update.objectStatus
- The object status to set.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | objectStatus is less than one |
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-030-000 | objectStatus is reserved. For example, it is positive, not a constant and less than 1024 . |
ALC-REP-036-000 | The object status was changed from latest to updated |
ALC-REP-037-000 | The object status was changed from other than latest to updated |
ALC-REP-038-000 | The object status was changed from updated to latest |
ALC-REP-039-000 | The object status was changed from other than updated to latest |
void updateProperties(java.lang.String resourceUri, ResourceProperty[] properties) throws RepositoryException
updateResource()
.
Pre-conditions:
properties
and its elements must not be null
.
Post-conditions:
resourceUri
is created.
resourceUri
- The resource to update.properties
- New or updated properties to set on the resource.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-019-000 | A property specified in properties is immutable |
void updateProperties(java.lang.String[] resourceUris, ResourceProperty[] properties) throws RepositoryException
Pre-conditions:
properties
and its elements must not be null
.
Post-conditions:
resourceUris
is created.
resourceUris
- An array of resources to update with the given properties.properties
- New or updated properties to set on the resource.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by an element of resourceUris is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by an element of resourceUris is locked |
ALC-REP-018-000 | The resource identified by an element of resourceUris does not exist or is not accessible |
ALC-REP-019-000 | A property specified in properties is immutable |
Resource updateResource(java.lang.String resourceUri, Resource resource, boolean revMajorVersion) throws RepositoryException
resourceUri
with the data in
resource
. The Lid
, major version, and minor version attributes on the supplied
resource are ignored, and are read from the resource identified by resourceUri
.
It is important to be aware that changing the name of a resource will break all prior path-based references.
For example, the resource will not be accessible by the old path.
Pre-conditions:
resourceUri
is Id
-based and revMajorVersion
is false
,
the next minor version of the resource identified by resourceUri
must be available.resourceUri
is Id
-based and revMajorVersion
is true
,
the next major version number (with the minor version equal to 0
) must be available.Post-conditions:
If the ownerVersion
attribute is set on resource
, ownerVersion
must be unique across all
versions of this logical resource.
resourceUri
- The version of the resource being updated.resource
- The new resource version.revMajorVersion
- If true
, the major version number is incrememted and the minor version
number is reset to zero. If false
, the minor version number is incremented and the major
version number is unchanged.
resource
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-020-000 | Pre-condition 2 failed |
ALC-REP-021-000 | Pre-condition 1 failed |
ALC-REP-022-000 | Pre-condition 1 failed |
void writeAccessControlList(java.lang.String resourceUri, AccessControlList accessControlList, boolean propagate) throws RepositoryException
accessControlList
on the resources
identified by the resourceUri
. If propagate
is true
and
resourceUri
identifies a ResourceCollection
,
the ACL will be applied to all members of the collection. Locking rules do not apply to the resource
identified by resourceUri
.
Post-conditions:
resourceId
has the permissions described by accessControlList
.
resourceUri
- The URI of the resource to which the ACL must be applied.accessControlList
- The ACL to apply to the resource identified by resourceId
.propagate
- When the resource is a ResourceCollection
,
this parameter determines whether the permissions
should be propagated to all path-contained resources.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
AccessControlList
void writeAccessControlList(java.lang.String resourceUri, AccessControlList accessControlList, short propagationMode) throws RepositoryException
accessControlList
on the resources
identified by the resourceUri
. If propagate
is true
and
resourceUri
identifies a ResourceCollection
,
the ACL will be applied to all members of the collection. Locking rules do not apply to the resource
identified by resourceUri
.
Post-conditions:
resourceId
has the permissions described by accessControlList
.
resourceUri
- The URI of the resource to which the ACL must be applied.accessControlList
- The ACL to apply to the resource identified by resourceId
.propagationMode
- When the resource is a ResourceCollection, this flag indicates whether to recursively
write the ACL to all child Resources, or to all non ResourceCollection immediate children in the specified
ResourceCollection or to not recursively write the ACL.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
AccessControlList
Resource writeResource(java.lang.String parentResourcePath, Resource resource) throws RepositoryException
Pre-conditions:
parentResourcePath
must be a path.parentResourcePath
must exist.parentResourcePath + / + resource.getName()
must not exist.If specified by the client:
Lid
attribute must be unique with respect to
all the Lid
attributes for other resources.Id
attribute must be unique with respect to
all the Id
attributes for other resources.Post-conditions:
Id
is generated.Lid
is generated.1.0
.
parentResourcePath
- The path to the ResourceCollection
that will contain the new Resource
.resource
- The new Resource
to create.
Resource
. The returned instance is not the same
instance as resource
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | parentResourcePath is not a path-based identifier |
ALC-REP-016-000 | The resource identified by parentResourcePath is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by parentResourcePath is locked |
ALC-REP-018-000 | The resource identified by parentResourcePath does not exist or is not accessible |
ALC-REP-028-000 | The major/minor combination is invalid |
ALC-REP-100-000 | The Id or Lid
is already in use by other resources |
Resource updateResourceWithId(java.lang.String resourceUri, java.lang.String resourceVersionId, boolean revMajorVersion) throws RepositoryException
resourceVersionId
parameter.
For more information, see updateResource()
.
resourceUri
- The version of the resource being updated.resourceVersionId
- The new resource version identifier.revMajorVersion
- If true
, the major version number is incremented and the minor version
number is reset to zero. If false
, the minor version number is incremented and the major
version number is unchanged.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-016-000 | The resource identified by resourceUri is locked by another user |
ALC-REP-017-000 | This error code is deprecated because it will never occur. The resource identified by resourceUri is locked |
ALC-REP-018-000 | The resource identified by resourceUri does not exist or is not accessible |
ALC-REP-020-000 | Pre-condition 2 of updateResource() failed |
ALC-REP-021-000 | Pre-condition 1 of updateResource() failed |
ALC-REP-022-000 | Pre-condition 1 of updateResource() failed |
void registerListener(ResourceRepositoryListenerEvent event, java.lang.String listenerName, ResourceRepositoryListener listener) throws RepositoryException
event
- - The ResourceRepositoryListenerEvent event which needs to be notifiedlistenerName
- - The listener name for the listener which will be registered for notifications of the specified Respository eventlistener
- - The specific listener which will be registered for notification of the specified Respository event
RepositoryException
void unregisterListener(ResourceRepositoryListenerEvent event, java.lang.String listenerName) throws RepositoryException
event
- - The ResourceRepositoryListenerEvent event which needs to be notifiedlistenerName
- - The listener name for the listener which will be registered for notifications of the specified Respository event
RepositoryException
java.util.List searchRelatedFilter(java.lang.String resourceUri, int relationshipType, int depth, Query query, int start, int maxResults, SortOrder sortOrder, java.lang.String appFilterName) throws RepositoryException
resourceUri
by a relation
of type relationshipType
and which also match the supplied criteria found in
the Query
object.
The resource identified by resourceUri
is taken to be the target of the relationships,
and infinite-depth searches recursively traverse relations from target to source.
The implementation supports results paging; both the start
and maxResults
parameters are zero-based.
resourceUri
- The Resource
for which to retrieve related resources.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater than or equal to 1024
.depth
- The depth of the search. Its possible values are
ResourceCollection.DEPTH_ONE
(search the base path only) or
ResourceCollection.DEPTH_INFINITE
(search the base path and all subfolders).query
- An instance of Query
describing a Repository query.start
- Indicates the first row to select from the unpaged result set.maxResults
- The maximum number of resources returned per page, starting at index start
of the entire result set.sortOrder
- Format and type TBDappFilterName
- String on which result is to be filtered
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | start is less than zero,
maxResults is less than one, or
relationshipType is less than one |
ALC-REP-018-000 | The resource identified resourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is reserved. For example, it is positive, not a constant and less than 1024 . |
Query
,
SortOrder
int getCount(java.lang.String resourceUri, int relationshipType, Query query, java.lang.String appFilterName) throws RepositoryException
resourceUri
by a relation
of type relationshipType
and which also match the supplied criteria found in
the Query
object.
The resource identified by resourceUri
is taken to be the target of the relationships,
and infinite-depth searches recursively traverse relations from target to source.
The implementation supports results paging; both the start
and maxResults
parameters are zero-based.
resourceUri
- The Resource
for which to retrieve related resources.relationshipType
- The type of relationship, chosen among the Relation
.TYPE_*
constants,
or a user-defined value greater than or equal to 1024
.query
- An instance of Query
describing a Repository query.appFilterName
- String on which result is to be filtered
java.util.List
of Resource
objects related to resourceUri
.
RepositoryException
- The following error codes indicate the error cause:Error code | Description |
---|---|
ALC-REP-013-000 | start is less than zero,
maxResults is less than one, or
relationshipType is less than one |
ALC-REP-018-000 | The resource identified resourceUri does not exist or is not accessible |
ALC-REP-030-000 | relationshipType is reserved. For example, it is positive, not a constant and less than 1024 . |
Query
,
SortOrder
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |