|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jackrabbit.commons.AbstractRepository
org.apache.jackrabbit.commons.repository.ProxyRepository
public class ProxyRepository
Repository that proxies all method calls to another repository.
The other repository is accessed lazily using a
repository factory
.
Field Summary |
---|
Constructor Summary | |
---|---|
protected |
ProxyRepository()
Protected constructor for subclasses that want to override the getRepository() method. |
|
ProxyRepository(Map<String,String> parameters)
Creates a proxy for the repository (or repositories) accessible using the given repository parameters. |
|
ProxyRepository(RepositoryFactory factory)
Creates a proxy for the repository (or repositories) accessible through the given factory. |
|
ProxyRepository(String uri)
Creates a proxy for the repository accessible using the given repository URI. |
Method Summary | |
---|---|
String |
getDescriptor(String key)
Returns the descriptor with the given key from the proxied repository. |
String[] |
getDescriptorKeys()
Returns the descriptor keys of the proxied repository, or an empty array if the proxied repository can not be accessed. |
Value |
getDescriptorValue(String key)
Returns the value of the descriptor with the given key from the proxied repository. |
Value[] |
getDescriptorValues(String key)
Returns the values of the descriptor with the given key from the proxied repository. |
protected Repository |
getRepository()
Returns the proxied repository. |
boolean |
isSingleValueDescriptor(String key)
Checks whether the given key identifies a valid single-valued descriptor key in the proxied repository. |
Session |
login(Credentials credentials,
String workspace)
Logs in to the proxied repository and returns the resulting session. |
Methods inherited from class org.apache.jackrabbit.commons.AbstractRepository |
---|
isStandardDescriptor, login, login, login |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ProxyRepository(RepositoryFactory factory)
factory
- repository factorypublic ProxyRepository(Map<String,String> parameters)
parameters
- repository parameterspublic ProxyRepository(String uri)
uri
- repository URIprotected ProxyRepository()
getRepository()
method.
Method Detail |
---|
protected Repository getRepository() throws RepositoryException
RepositoryException
- if the repository can not be accessedpublic String[] getDescriptorKeys()
public boolean isSingleValueDescriptor(String key)
false
if the proxied repository can not be accessed.
true
if the key identifies a valid single-valued
descriptor in the proxied repository,
false
otherwisepublic String getDescriptor(String key)
null
if the descriptor does not exist or if the
proxied repository can not be accessed.
key
- descriptor key
null
public Value getDescriptorValue(String key)
null
if the descriptor does not exist
or if the proxied repository can not be accessed.
key
- descriptor key
null
public Value[] getDescriptorValues(String key)
null
if the descriptor does not exist
or if the proxied repository can not be accessed.
key
- descriptor key
null
public Session login(Credentials credentials, String workspace) throws RepositoryException
Note that the Session.getRepository()
method of the resulting
session will return the proxied repository, not this repository proxy!
RepositoryException
- if the proxied repository can not be
accessed, or if the login in the proxied
repository fails
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |