org.apache.jackrabbit.decorator
Class RepositoryDecorator

java.lang.Object
  extended byorg.apache.jackrabbit.decorator.RepositoryDecorator
All Implemented Interfaces:
Repository

public class RepositoryDecorator
extends Object
implements Repository

Simple Repository decorator.


Field Summary
 
Fields inherited from interface javax.jcr.Repository
LEVEL_1_SUPPORTED, LEVEL_2_SUPPORTED, OPTION_LOCKING_SUPPORTED, OPTION_OBSERVATION_SUPPORTED, OPTION_QUERY_SQL_SUPPORTED, OPTION_TRANSACTIONS_SUPPORTED, OPTION_VERSIONING_SUPPORTED, QUERY_XPATH_DOC_ORDER, QUERY_XPATH_POS_INDEX, REP_NAME_DESC, REP_VENDOR_DESC, REP_VENDOR_URL_DESC, REP_VERSION_DESC, SPEC_NAME_DESC, SPEC_VERSION_DESC
 
Constructor Summary
RepositoryDecorator(DecoratorFactory factory, Repository repository)
           
 
Method Summary
 String getDescriptor(String key)
          Forwards the method call to the underlying repository.
 String[] getDescriptorKeys()
          Forwards the method call to the underlying repository.
 Session login()
          Calls login(null, null).
 Session login(Credentials credentials)
          Calls login(credentials, null).
 Session login(Credentials credentials, String workspaceName)
          Forwards the method call to the underlying repository.
 Session login(String workspaceName)
          Calls login(null, workspaceName).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RepositoryDecorator

public RepositoryDecorator(DecoratorFactory factory,
                           Repository repository)
Method Detail

getDescriptorKeys

public String[] getDescriptorKeys()
Forwards the method call to the underlying repository.

Specified by:
getDescriptorKeys in interface Repository

getDescriptor

public String getDescriptor(String key)
Forwards the method call to the underlying repository.

Specified by:
getDescriptor in interface Repository

login

public Session login(Credentials credentials,
                     String workspaceName)
              throws LoginException,
                     NoSuchWorkspaceException,
                     RepositoryException
Forwards the method call to the underlying repository. The returned session is wrapped into a session decorator using the decorator factory.

Specified by:
login in interface Repository
Returns:
decorated session
Throws:
LoginException
NoSuchWorkspaceException
RepositoryException

login

public Session login(Credentials credentials)
              throws LoginException,
                     NoSuchWorkspaceException,
                     RepositoryException
Calls login(credentials, null).

Specified by:
login in interface Repository
Returns:
decorated session
Throws:
LoginException
NoSuchWorkspaceException
RepositoryException
See Also:
login(Credentials, String)

login

public Session login(String workspaceName)
              throws LoginException,
                     NoSuchWorkspaceException,
                     RepositoryException
Calls login(null, workspaceName).

Specified by:
login in interface Repository
Returns:
decorated session
Throws:
LoginException
NoSuchWorkspaceException
RepositoryException
See Also:
login(Credentials, String)

login

public Session login()
              throws LoginException,
                     NoSuchWorkspaceException,
                     RepositoryException
Calls login(null, null).

Specified by:
login in interface Repository
Returns:
decorated session
Throws:
LoginException
NoSuchWorkspaceException
RepositoryException
See Also:
login(Credentials, String)


Copyright © 2004-2005 . All Rights Reserved.