@ThreadSafe public class RepositoryManager extends Object
ServiceLoader and RepositoriesContainer mechanism.| Modifier and Type | Method and Description |
|---|---|
static Set<String> |
getJcrRepositoryNames()
Returns a set with all the names of the available repositories.
|
static javax.jcr.Repository |
getRepository(String repositoryName)
Returns the
Repository instance with the given name. |
static javax.jcr.Session |
getSession(javax.servlet.http.HttpServletRequest request,
String repositoryName,
String workspaceName)
Get a JCR Session for the named workspace in the named repository, using the supplied HTTP servlet request for
authentication information.
|
public static javax.jcr.Session getSession(javax.servlet.http.HttpServletRequest request, String repositoryName, String workspaceName) throws javax.jcr.RepositoryException
request - the servlet request; may not be null or unauthenticatedrepositoryName - the name of the repository in which the session is createdworkspaceName - the name of the workspace to which the session should be connectedjavax.jcr.RepositoryException - if the named repository does not exist or there was a problem obtaining the named repositorypublic static javax.jcr.Repository getRepository(String repositoryName) throws NoSuchRepositoryException
Repository instance with the given name.repositoryName - a non-null stringRepository instance, never nullNoSuchRepositoryException - if no repository with the given name exists.public static Set<String> getJcrRepositoryNames()
nullCopyright © 2008–2018 JBoss, a division of Red Hat. All rights reserved.