Class SessionFactoryImpl
java.lang.Object
org.exoplatform.connectors.jcr.impl.adapter.SessionFactoryImpl
- All Implemented Interfaces:
Serializable,Referenceable,javax.resource.Referenceable,SessionFactory
public class SessionFactoryImpl
extends Object
implements SessionFactory, javax.resource.Referenceable
The default implementation of the
SessionFactory.- Version:
- $Id$
- Author:
- Nicolas Filotto
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionjavax.jcr.SessionGet a JCR session corresponding to the repository defined in the configuration and the default workspace.javax.jcr.SessiongetSession(String workspace) Get a JCR session corresponding to the repository defined in the configuration and the given workspace.javax.jcr.SessiongetSession(String userName, String password) Get a JCR session corresponding to the repository defined in the configuration and the default workspace, using the given user name and password.javax.jcr.SessiongetSession(String workspace, String userName, String password) Get a JCR session corresponding to the repository defined in the configuration and the given workspace, using the given user name and password.voidsetReference(Reference reference)
-
Method Details
-
setReference
- Specified by:
setReferencein interfacejavax.resource.Referenceable- See Also:
-
getReference
- Specified by:
getReferencein interfaceReferenceable- Throws:
NamingException- See Also:
-
getSession
public javax.jcr.Session getSession() throws javax.jcr.RepositoryExceptionDescription copied from interface:SessionFactoryGet a JCR session corresponding to the repository defined in the configuration and the default workspace.- Specified by:
getSessionin interfaceSessionFactory- Returns:
- a JCR session corresponding to the criteria
- Throws:
javax.jcr.RepositoryException- if the session could not be created- See Also:
-
getSession
public javax.jcr.Session getSession(String userName, String password) throws javax.jcr.RepositoryException Description copied from interface:SessionFactoryGet a JCR session corresponding to the repository defined in the configuration and the default workspace, using the given user name and password.- Specified by:
getSessionin interfaceSessionFactory- Parameters:
userName- the user name to use for the authenticationpassword- the password to use for the authentication- Returns:
- a JCR session corresponding to the criteria
- Throws:
javax.jcr.RepositoryException- if the session could not be created- See Also:
-
getSession
Description copied from interface:SessionFactoryGet a JCR session corresponding to the repository defined in the configuration and the given workspace.- Specified by:
getSessionin interfaceSessionFactory- Parameters:
workspace- the name of the expected workspace- Returns:
- a JCR session corresponding to the criteria
- Throws:
javax.jcr.RepositoryException- if the session could not be created- See Also:
-
getSession
public javax.jcr.Session getSession(String workspace, String userName, String password) throws javax.jcr.RepositoryException Description copied from interface:SessionFactoryGet a JCR session corresponding to the repository defined in the configuration and the given workspace, using the given user name and password.- Specified by:
getSessionin interfaceSessionFactory- Parameters:
workspace- the name of the expected workspaceuserName- the user name to use for the authenticationpassword- the password to use for the authentication- Returns:
- a JCR session corresponding to the criteria
- Throws:
javax.jcr.RepositoryException- if the session could not be created- See Also:
-