public class RepositoryService extends DefaultComponent
Modifier and Type | Field and Description |
---|---|
static ComponentName |
NAME |
static String |
XP_REPOSITORY |
Constructor and Description |
---|
RepositoryService() |
Modifier and Type | Method and Description |
---|---|
void |
applicationStarted(ComponentContext context)
Notify the component that Nuxeo Framework finished starting all Nuxeo bundles.
|
<T> T |
getAdapter(Class<T> adapter)
Returns an object which is an instance of the given class associated with this object.
|
int |
getApplicationStartedOrder()
The component notification order for
Component.applicationStarted(org.nuxeo.runtime.model.ComponentContext) . |
Repository |
getRepository(String repositoryName)
Gets a repository given its name.
|
List<String> |
getRepositoryNames() |
Session |
getSession(String repositoryName,
String sessionId)
Creates a new session with the given session id from the given repository.
|
void |
shutdown() |
activate, deactivate, getLastModified, registerContribution, registerExtension, setLastModified, unregisterContribution, unregisterExtension
public static final ComponentName NAME
public static final String XP_REPOSITORY
public void shutdown()
public int getApplicationStartedOrder()
Component
Component.applicationStarted(org.nuxeo.runtime.model.ComponentContext)
.
Components are notified in increasing order. Order 1000 is the default order for components that don't care. Order 100 is the repository initialization.
getApplicationStartedOrder
in interface Component
getApplicationStartedOrder
in class DefaultComponent
public void applicationStarted(ComponentContext context)
Component
applicationStarted
in interface Component
applicationStarted
in class DefaultComponent
public <T> T getAdapter(Class<T> adapter)
Adaptable
null
if no such object can be found.getAdapter
in interface Adaptable
getAdapter
in class DefaultComponent
adapter
- the adapter class to look upnull
if this object does not have an adapter for
the given classpublic Repository getRepository(String repositoryName)
Null is returned if no repository with that name was registered.
repositoryName
- the repository nameCopyright © 2015 Nuxeo SA. All rights reserved.