|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eclipse.stardust.engine.core.spi.dms.RepositoryIdUtils
public class RepositoryIdUtils
Utility to handle the repositoryId prefix of Resource.getId() and Resource.getId().
| Field Summary | |
|---|---|
static String |
REPOSITORY_ID_PREFIX
The prefix that is used to identify a repositoryId. |
| Method Summary | ||
|---|---|---|
static Documents |
addRepositoryId(Documents documents,
String repositoryId)
|
|
static
|
addRepositoryId(List<T> resources,
String repositoryId)
|
|
static String |
addRepositoryId(String id,
String repositoryId)
|
|
static
|
addRepositoryId(T resource,
String repositoryId)
|
|
static List<String> |
extractRepositoryId(List<String> prefixedIds)
|
|
static String |
extractRepositoryId(Resource resource)
|
|
static String |
extractRepositoryId(String prefixedId)
|
|
static String |
replaceRepositoryId(String prefixedId,
String newRepositoryId)
|
|
static boolean |
repositoryIdEquals(String repositoryId1,
String repositoryId2)
Compares repositoryIds considering legacy id null which defaults to
RepositoryManager.SYSTEM_REPOSITORY_ID. |
|
static boolean |
resourceIdEquals(String id1,
String id2)
Compares Resource Ids considering legacy Ids without repositoryId prefix.The prefix pointing to the repositoryId RepositoryManager.SYSTEM_REPOSITORY_ID is optional. |
|
static List<String> |
stripRepositoryId(List<String> prefixedIds)
|
|
static String |
stripRepositoryId(String prefixedId)
|
|
static
|
stripRepositoryId(T resource)
|
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String REPOSITORY_ID_PREFIX
| Method Detail |
|---|
public static String extractRepositoryId(String prefixedId)
public static List<String> extractRepositoryId(List<String> prefixedIds)
public static String extractRepositoryId(Resource resource)
public static String stripRepositoryId(String prefixedId)
public static List<String> stripRepositoryId(List<String> prefixedIds)
public static <T extends Resource> T stripRepositoryId(T resource)
public static String addRepositoryId(String id,
String repositoryId)
public static <T extends Resource> T addRepositoryId(T resource,
String repositoryId)
public static <T extends Resource> List<T> addRepositoryId(List<T> resources,
String repositoryId)
public static Documents addRepositoryId(Documents documents,
String repositoryId)
public static String replaceRepositoryId(String prefixedId,
String newRepositoryId)
public static boolean resourceIdEquals(String id1,
String id2)
Resource Ids considering legacy Ids without repositoryId prefix.RepositoryManager.SYSTEM_REPOSITORY_ID is optional.
Do not confuse with repositoryIdEquals(String, String)
For example:
'{urn:repository:default}{jcr-uuid}ABC' == '{jcr-uuid}ABC'.
However:
'{urn:repository:newRepository}{jcr-uuid}ABC' != '{jcr-uuid}ABC'
public static boolean repositoryIdEquals(String repositoryId1,
String repositoryId2)
null which defaults to
RepositoryManager.SYSTEM_REPOSITORY_ID.
Do not confuse with resourceIdEquals(String, String).
For example:
'default == null'
However:
'newRepository != null'
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||