public class SessionFactory extends Object
| Constructor and Description |
|---|
SessionFactory()
initialize an empty session factory
|
SessionFactory(javax.jcr.Repository repo,
TransactionService transactionService)
Initialize a session factory for the given Repository
|
| Modifier and Type | Method and Description |
|---|---|
javax.jcr.Session |
getSession()
Get a new JCR Session
|
javax.jcr.Session |
getSession(javax.servlet.http.HttpServletRequest servletRequest)
Get a JCR session for the given HTTP servlet request (within the right
transaction or workspace)
|
javax.jcr.Session |
getSession(javax.ws.rs.core.SecurityContext securityContext,
javax.servlet.http.HttpServletRequest servletRequest)
Get a JCR session for the given HTTP servlet request with a
SecurityContext attached
|
javax.jcr.Session |
getSession(String workspace)
Get a new JCR session in the given workspace
|
AuthenticatedSessionProvider |
getSessionProvider(javax.ws.rs.core.SecurityContext securityContext,
javax.servlet.http.HttpServletRequest servletRequest)
Get the configured Session Provider
|
void |
init()
Validate the spring wiring
|
public SessionFactory()
public SessionFactory(javax.jcr.Repository repo,
TransactionService transactionService)
repo - transactionService - @PostConstruct public void init()
public javax.jcr.Session getSession()
throws javax.jcr.RepositoryException
javax.jcr.RepositoryExceptionpublic javax.jcr.Session getSession(String workspace) throws javax.jcr.RepositoryException
workspace - javax.jcr.RepositoryExceptionpublic javax.jcr.Session getSession(javax.servlet.http.HttpServletRequest servletRequest)
throws javax.jcr.RepositoryException
servletRequest - javax.jcr.RepositoryExceptionpublic javax.jcr.Session getSession(javax.ws.rs.core.SecurityContext securityContext,
javax.servlet.http.HttpServletRequest servletRequest)
securityContext - servletRequest - public AuthenticatedSessionProvider getSessionProvider(javax.ws.rs.core.SecurityContext securityContext, javax.servlet.http.HttpServletRequest servletRequest)
securityContext - servletRequest - Copyright © 2013 DuraSpace, Inc.. All Rights Reserved.