public class FilterRepositoryFactory extends Object implements RepositoryFactory
The default name of the repository attribute is
"javax.jcr.Repository
", but it can be changed by specifying
an init parameter with the same name:
<filter> <init-param> <param-name>javax.jcr.Repository</param-name> <param-value>my.repository.attribute</param-value> <description> This init parameter causes the repository to be looked up from the "my.repository.attribute" attribute instead of the default "javax.jcr.Repository". </description> </init-param> </filter>
Constructor and Description |
---|
FilterRepositoryFactory(javax.servlet.FilterConfig config)
Creates a factory for looking up a repository from the context
associated with the given filter configuration.
|
Modifier and Type | Method and Description |
---|---|
Repository |
getRepository()
Looks up and returns a repository bound in the servlet context of
the given filter.
|
public FilterRepositoryFactory(javax.servlet.FilterConfig config)
config
- filter configurationpublic Repository getRepository() throws RepositoryException
getRepository
in interface RepositoryFactory
RepositoryException
- if the repository is not availableCopyright © 2004–2023 The Apache Software Foundation. All rights reserved.