Package org.apache.jackrabbit.commons
Class JndiRepositoryFactory
- java.lang.Object
-
- org.apache.jackrabbit.commons.JndiRepositoryFactory
-
- All Implemented Interfaces:
RepositoryFactory
- Direct Known Subclasses:
GenericRepositoryFactory
public class JndiRepositoryFactory extends Object implements RepositoryFactory
JNDI-based JCR repository factory. This factory looks upRepository
instances from JNDI directories based on the following parameters:org.apache.jackrabbit.repository.jndi.name
- The value of this parameter is used as a JNDI name for looking up the repository.
org.apache.jackrabbit.repository.uri
- If the URI scheme is "jndi", then the remainder of the URI is used as a JNDI name for looking up the repository.
All the other repository parameters are passed as the environment of the
initial JNDI context
.Clients should normally only use this class through the Java Service Provider mechanism. See the getRepository utility methods in
JcrUtils
for an easy way to do that.- Since:
- Apache Jackrabbit 2.0
-
-
Constructor Summary
Constructors Constructor Description JndiRepositoryFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Repository
getRepository(Map parameters)
-
-
-
Field Detail
-
JNDI_NAME
public static final String JNDI_NAME
The JNDI name parameter name.- See Also:
- Constant Field Values
-
-
Method Detail
-
getRepository
public Repository getRepository(Map parameters) throws RepositoryException
- Specified by:
getRepository
in interfaceRepositoryFactory
- Throws:
RepositoryException
-
-