org.apache.jackrabbit.rmi.client
Class ClientWorkspace

java.lang.Object
  extended byorg.apache.jackrabbit.rmi.client.ClientObject
      extended byorg.apache.jackrabbit.rmi.client.ClientWorkspace
All Implemented Interfaces:
Workspace

public class ClientWorkspace
extends ClientObject
implements Workspace

Local adapter for the JCR-RMI RemoteWorkspace interface. This class makes a remote workspace locally available using the JCR Workspace interface.

Author:
Jukka Zitting, Philipp Koch
See Also:
Workspace, RemoteWorkspace

Constructor Summary
ClientWorkspace(Session session, RemoteWorkspace remote, LocalAdapterFactory factory)
          Creates a client adapter for the given remote workspace.
 
Method Summary
 void clone(String workspace, String src, String dst, boolean removeExisting)
          
 void copy(String from, String to)
          
 void copy(String workspace, String from, String to)
          
 String[] getAccessibleWorkspaceNames()
          
 ContentHandler getImportContentHandler(String path, int uuidBehaviour)
          
 String getName()
          
 NamespaceRegistry getNamespaceRegistry()
          
 NodeTypeManager getNodeTypeManager()
          
 ObservationManager getObservationManager()
          
 QueryManager getQueryManager()
          
 Session getSession()
          Returns the current session without contacting the remote workspace.
 void importXML(String path, InputStream xml, int uuidBehaviour)
          
 void move(String from, String to)
          
 void restore(Version[] versions, boolean removeExisting)
          
 
Methods inherited from class org.apache.jackrabbit.rmi.client.ClientObject
getFactory, getItem, getNode, getNodeTypeArray
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClientWorkspace

public ClientWorkspace(Session session,
                       RemoteWorkspace remote,
                       LocalAdapterFactory factory)
Creates a client adapter for the given remote workspace.

Parameters:
session - current session
remote - remote workspace
factory - local adapter factory
Method Detail

getSession

public Session getSession()
Returns the current session without contacting the remote workspace.

Specified by:
getSession in interface Workspace

getName

public String getName()

Specified by:
getName in interface Workspace

copy

public void copy(String from,
                 String to)
          throws RepositoryException

Specified by:
copy in interface Workspace
Throws:
RepositoryException

copy

public void copy(String workspace,
                 String from,
                 String to)
          throws RepositoryException

Specified by:
copy in interface Workspace
Throws:
RepositoryException

move

public void move(String from,
                 String to)
          throws RepositoryException

Specified by:
move in interface Workspace
Throws:
RepositoryException

getQueryManager

public QueryManager getQueryManager()
                             throws RepositoryException

Specified by:
getQueryManager in interface Workspace
Throws:
RepositoryException

getNamespaceRegistry

public NamespaceRegistry getNamespaceRegistry()
                                       throws RepositoryException

Specified by:
getNamespaceRegistry in interface Workspace
Throws:
RepositoryException

getNodeTypeManager

public NodeTypeManager getNodeTypeManager()
                                   throws RepositoryException

Specified by:
getNodeTypeManager in interface Workspace
Throws:
RepositoryException

getObservationManager

public ObservationManager getObservationManager()
                                         throws RepositoryException

Specified by:
getObservationManager in interface Workspace
Throws:
RepositoryException

clone

public void clone(String workspace,
                  String src,
                  String dst,
                  boolean removeExisting)
           throws RepositoryException

Specified by:
clone in interface Workspace
Throws:
RepositoryException

getAccessibleWorkspaceNames

public String[] getAccessibleWorkspaceNames()
                                     throws RepositoryException

Specified by:
getAccessibleWorkspaceNames in interface Workspace
Throws:
RepositoryException

getImportContentHandler

public ContentHandler getImportContentHandler(String path,
                                              int uuidBehaviour)
                                       throws RepositoryException

Specified by:
getImportContentHandler in interface Workspace
Throws:
RepositoryException

importXML

public void importXML(String path,
                      InputStream xml,
                      int uuidBehaviour)
               throws IOException,
                      RepositoryException

Specified by:
importXML in interface Workspace
Throws:
IOException
RepositoryException

restore

public void restore(Version[] versions,
                    boolean removeExisting)
             throws RepositoryException

Specified by:
restore in interface Workspace
Throws:
RepositoryException


Copyright © 2004-2006 . All Rights Reserved.