|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.admin.registry.RegistryServiceImpl
public class RegistryServiceImpl
Implementation of registry service to provide generic storage and retrieval of system-related metadata.
Constructor Summary | |
---|---|
RegistryServiceImpl()
|
Method Summary | |
---|---|
void |
addProperty(RegistryKey key,
java.io.Serializable value)
Assign a value to the registry key, which must be of the form /a/b/c. |
void |
copy(RegistryKey sourceKey,
RegistryKey targetKey)
Copies the path or value from the source to the target location. |
void |
delete(RegistryKey key)
Delete the path element or value described by the key. |
java.util.Collection |
getChildElements(RegistryKey key)
Fetches all child elements for the given path. |
java.io.Serializable |
getProperty(RegistryKey key)
|
void |
init()
|
void |
setNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService)
|
void |
setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
|
void |
setRegistryRootPath(java.lang.String registryRootPath)
A root path e.g. |
void |
setRegistryStore(java.lang.String registryStore)
|
void |
setRegistryStoreRef(org.alfresco.service.cmr.repository.StoreRef registryStoreRef)
|
void |
setSearchService(org.alfresco.service.cmr.search.SearchService searchService)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RegistryServiceImpl()
Method Detail |
---|
public void setNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService)
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
public void setSearchService(org.alfresco.service.cmr.search.SearchService searchService)
public void setRegistryStoreRef(org.alfresco.service.cmr.repository.StoreRef registryStoreRef)
registryStoreRef
- the store in which the registry root is foundpublic void setRegistryStore(java.lang.String registryStore)
RegistryServiceImpl.setRegistryStoreRef(StoreRef)
public void setRegistryRootPath(java.lang.String registryRootPath)
registryRootPath
- the path to the root of the registrypublic void init()
public void addProperty(RegistryKey key, java.io.Serializable value)
addProperty
in interface RegistryService
key
- the registry key.value
- any value that can be stored in the repository.public java.io.Serializable getProperty(RegistryKey key)
getProperty
in interface RegistryService
key
- the registry key.
#addProperty(String, Serializable)
public java.util.Collection getChildElements(RegistryKey key)
RegistryService
...
registryService.addValue(KEY_A_B_C_1, VALUE_ONE);
registryService.addValue(KEY_A_B_C_2, VALUE_TWO);
...
assertTrue(registryService.getChildElements(KEY_A_B_null).contains("C"));
...
getChildElements
in interface RegistryService
key
- the registry key with the path. The last element in the path
will be ignored, and can be any acceptable value localname or null.
RegistryKey.getPath()
public void copy(RegistryKey sourceKey, RegistryKey targetKey)
RegistryService
This is essentially a merge operation. Use delete
first
if the target must be cleaned.
copy
in interface RegistryService
sourceKey
- the source registry key to take values fromtargetKey
- the target registyr key to move the path or value topublic void delete(RegistryKey key)
RegistryService
delete(/a/b/c)
will remove value c from path /a/b.delete(/a/b/null)
will remove node /a/b along with all values and child
elements.
delete
in interface RegistryService
key
- the path or value to delete
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |