org.exist.soap
Class AdminSoapBindingSkeleton

java.lang.Object
  extended byorg.exist.soap.AdminSoapBindingSkeleton
All Implemented Interfaces:
Admin, java.rmi.Remote, java.io.Serializable, org.apache.axis.wsdl.Skeleton

public class AdminSoapBindingSkeleton
extends java.lang.Object
implements Admin, org.apache.axis.wsdl.Skeleton

See Also:
Serialized Form

Constructor Summary
AdminSoapBindingSkeleton()
           
AdminSoapBindingSkeleton(Admin impl)
           
 
Method Summary
 java.lang.String connect(java.lang.String userId, java.lang.String password)
          Create a new user session.
 void copyCollection(java.lang.String sessionId, java.lang.String collectionPath, java.lang.String destinationPath, java.lang.String newName)
          Copy a collection to the destination collection and rename it.
 void copyResource(java.lang.String sessionId, java.lang.String docPath, java.lang.String destinationPath, java.lang.String newName)
          Copy a resource to the destination collection and rename it.
 boolean createCollection(java.lang.String sessionId, java.lang.String path)
          Create a new collection using the specified path.
 void disconnect(java.lang.String sessionId)
          Release a user session.
 byte[] getBinaryResource(java.lang.String sessionId, java.lang.String name)
          Retrieve a binary resource from the database
 CollectionDesc getCollectionDesc(java.lang.String sessionId, java.lang.String collectionName)
          Obtain a description of the specified collection.
 Strings getGroups(java.lang.String sessionId)
          Obtain a list of the defined database groups
 IndexedElements getIndexedElements(java.lang.String sessionId, java.lang.String collectionName, boolean inclusive)
          Return a list of Indexed Elements for a collection
static java.util.List getOperationDescByName(java.lang.String methodName)
          Returns List of OperationDesc objects with this name
static java.util.Collection getOperationDescs()
          Returns Collection of OperationDescs
 Permissions getPermissions(java.lang.String sessionId, java.lang.String resource)
          Return the permissions of the specified collection/document
 UserDesc getUser(java.lang.String sessionId, java.lang.String user)
          Obtain information about an eXist user.
 UserDescs getUsers(java.lang.String sessionId)
          Get an list of users
 java.lang.String hasUserLock(java.lang.String sessionId, java.lang.String path)
          Return the name of the user owning the lock on the specified resource
 EntityPermissionsList listCollectionPermissions(java.lang.String sessionId, java.lang.String name)
          Return a list of the permissions of the child collections of the specified parent collection
 EntityPermissionsList listDocumentPermissions(java.lang.String sessionId, java.lang.String name)
          Return a list of the permissions of the child documents of the specified parent collection
 void lockResource(java.lang.String sessionId, java.lang.String path, java.lang.String userName)
          Place a write lock on the specified resource
 void moveCollection(java.lang.String sessionId, java.lang.String collectionPath, java.lang.String destinationPath, java.lang.String newName)
          Move a collection and its contents.
 void moveResource(java.lang.String sessionId, java.lang.String docPath, java.lang.String destinationPath, java.lang.String newName)
          Move a resource.
 boolean removeCollection(java.lang.String sessionId, java.lang.String path)
          Remove the specified collection.
 boolean removeDocument(java.lang.String sessionId, java.lang.String path)
          Remove the specified document.
 void removeUser(java.lang.String sessionId, java.lang.String name)
          Remove an eXist user account.
 void setPermissions(java.lang.String sessionId, java.lang.String resource, java.lang.String owner, java.lang.String ownerGroup, int permissions)
          Set the owner, group and access permissions for a document or collection
 void setUser(java.lang.String sessionId, java.lang.String name, java.lang.String password, Strings groups, java.lang.String home)
          Create a new user.
 void store(java.lang.String sessionId, byte[] data, java.lang.String encoding, java.lang.String path, boolean replace)
          Store a new document into the database.
 void storeBinary(java.lang.String sessionId, byte[] data, java.lang.String path, java.lang.String mimeType, boolean replace)
          Store a binary resource in the database
 void unlockResource(java.lang.String sessionId, java.lang.String path)
          Release the lock on the specified resource
 int xupdate(java.lang.String sessionId, java.lang.String collectionName, java.lang.String xupdate)
          Apply a set of XUpdate modifications to a collection.
 int xupdateResource(java.lang.String sessionId, java.lang.String documentName, java.lang.String xupdate)
          Apply a set of XUpdate modifications to the specified document.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AdminSoapBindingSkeleton

public AdminSoapBindingSkeleton()

AdminSoapBindingSkeleton

public AdminSoapBindingSkeleton(Admin impl)
Method Detail

getOperationDescByName

public static java.util.List getOperationDescByName(java.lang.String methodName)
Returns List of OperationDesc objects with this name


getOperationDescs

public static java.util.Collection getOperationDescs()
Returns Collection of OperationDescs


store

public void store(java.lang.String sessionId,
                  byte[] data,
                  java.lang.String encoding,
                  java.lang.String path,
                  boolean replace)
           throws java.rmi.RemoteException
Description copied from interface: Admin
Store a new document into the database. The document will be stored using the name and location as specified by the path argument. To avoid any conflicts with the SOAP transport layer, document contents are passed as base64 encoded binary data. Internally, all documents are stored in UTF-8 encoding. The method will automatically replace an already existing document with the same path if the replace argument is set to true (and the user has sufficient privileges).

Specified by:
store in interface Admin
Parameters:
sessionId - a unique id for the created session.
data - the document contents as base64 encoded binary data.
encoding - the character encoding used for the document data.
path - the target path for the new document.
replace - should an existing document be replaced?
Throws:
java.rmi.RemoteException

connect

public java.lang.String connect(java.lang.String userId,
                                java.lang.String password)
                         throws java.rmi.RemoteException
Description copied from interface: Admin
Create a new user session. Authenticates the user against the database. The user has to be a valid database user. If the provided user information is valid, a new session will be registered on the server and a session id will be returned. The session will be valid for at least 60 minutes. Please call disconnect() to release the session. Sessions are shared between the Query and Admin services. A session created through the Query service can be used with the Admin service and vice versa.

Specified by:
connect in interface Admin
Parameters:
userId -
password -
Returns:
session-id a unique id for the created session
Throws:
java.rmi.RemoteException - if the user cannot log in

disconnect

public void disconnect(java.lang.String sessionId)
                throws java.rmi.RemoteException
Description copied from interface: Admin
Release a user session. This will free all resources (including result sets).

Specified by:
disconnect in interface Admin
Parameters:
sessionId - a valid session id as returned by connect().
Throws:
java.rmi.RemoteException

removeCollection

public boolean removeCollection(java.lang.String sessionId,
                                java.lang.String path)
                         throws java.rmi.RemoteException
Description copied from interface: Admin
Remove the specified collection.

Specified by:
removeCollection in interface Admin
Parameters:
sessionId - sessionId a unique id for the created session.
path - the full path to the collection.
Returns:
true on success.
Throws:
java.rmi.RemoteException

removeDocument

public boolean removeDocument(java.lang.String sessionId,
                              java.lang.String path)
                       throws java.rmi.RemoteException
Description copied from interface: Admin
Remove the specified document.

Specified by:
removeDocument in interface Admin
Parameters:
sessionId - a unique id for the created session.
path - the full path to the document.
Returns:
true on success.
Throws:
java.rmi.RemoteException

createCollection

public boolean createCollection(java.lang.String sessionId,
                                java.lang.String path)
                         throws java.rmi.RemoteException
Description copied from interface: Admin
Create a new collection using the specified path.

Specified by:
createCollection in interface Admin
Parameters:
sessionId - a unique id for the created session.
path - the full path to the collection.
Throws:
java.rmi.RemoteException

xupdate

public int xupdate(java.lang.String sessionId,
                   java.lang.String collectionName,
                   java.lang.String xupdate)
            throws java.rmi.RemoteException
Description copied from interface: Admin
Apply a set of XUpdate modifications to a collection.

Specified by:
xupdate in interface Admin
Parameters:
sessionId - a unique id for the created session.
collectionName - the full path to the collection.
xupdate - the XUpdate document to be applied.
Throws:
java.rmi.RemoteException

xupdateResource

public int xupdateResource(java.lang.String sessionId,
                           java.lang.String documentName,
                           java.lang.String xupdate)
                    throws java.rmi.RemoteException
Description copied from interface: Admin
Apply a set of XUpdate modifications to the specified document.

Specified by:
xupdateResource in interface Admin
Parameters:
sessionId - a unique id for the created session.
documentName - the full path to the document.
xupdate - the XUpdate document to be applied.
Throws:
java.rmi.RemoteException

getBinaryResource

public byte[] getBinaryResource(java.lang.String sessionId,
                                java.lang.String name)
                         throws java.rmi.RemoteException
Description copied from interface: Admin
Retrieve a binary resource from the database

Specified by:
getBinaryResource in interface Admin
Parameters:
sessionId - the session identifier
name - the name of the binary resource
Returns:
the binary resource data
Throws:
java.rmi.RemoteException

getCollectionDesc

public CollectionDesc getCollectionDesc(java.lang.String sessionId,
                                        java.lang.String collectionName)
                                 throws java.rmi.RemoteException
Description copied from interface: Admin
Obtain a description of the specified collection. The description contains - the collection permissions - list of sub-collections - list of documents and their permissions

Specified by:
getCollectionDesc in interface Admin
Parameters:
sessionId - the session identifier
collectionName - the collection
Returns:
the collection descriptor
Throws:
java.rmi.RemoteException

setPermissions

public void setPermissions(java.lang.String sessionId,
                           java.lang.String resource,
                           java.lang.String owner,
                           java.lang.String ownerGroup,
                           int permissions)
                    throws java.rmi.RemoteException
Description copied from interface: Admin
Set the owner, group and access permissions for a document or collection

Specified by:
setPermissions in interface Admin
Parameters:
sessionId - the session id
resource - the document/collection that will get new permissions
owner - the new owner
ownerGroup - the new group
permissions - the new access permissions
Throws:
java.rmi.RemoteException

copyResource

public void copyResource(java.lang.String sessionId,
                         java.lang.String docPath,
                         java.lang.String destinationPath,
                         java.lang.String newName)
                  throws java.rmi.RemoteException
Description copied from interface: Admin
Copy a resource to the destination collection and rename it.

Specified by:
copyResource in interface Admin
Parameters:
sessionId - the session identifier
docPath - the resource to cop
destinationPath - the destination collection
newName - the new name for the resource
Throws:
java.rmi.RemoteException

copyCollection

public void copyCollection(java.lang.String sessionId,
                           java.lang.String collectionPath,
                           java.lang.String destinationPath,
                           java.lang.String newName)
                    throws java.rmi.RemoteException
Description copied from interface: Admin
Copy a collection to the destination collection and rename it.

Specified by:
copyCollection in interface Admin
Parameters:
sessionId - the session identifier
collectionPath - the collection to rename
destinationPath - the destination collection
newName - the new name of the collection.
Throws:
java.rmi.RemoteException

setUser

public void setUser(java.lang.String sessionId,
                    java.lang.String name,
                    java.lang.String password,
                    Strings groups,
                    java.lang.String home)
             throws java.rmi.RemoteException
Description copied from interface: Admin
Create a new user. Requires Admin privilege.

Specified by:
setUser in interface Admin
Parameters:
sessionId - the session identifier
name - the name of the new user
password - the password for the new user
groups - the new user should belong to these groups
Throws:
java.rmi.RemoteException

getUser

public UserDesc getUser(java.lang.String sessionId,
                        java.lang.String user)
                 throws java.rmi.RemoteException
Description copied from interface: Admin
Obtain information about an eXist user.

Specified by:
getUser in interface Admin
Parameters:
sessionId - the session identifier
user - the user
Returns:
the user information - name, groups and home collection
Throws:
java.rmi.RemoteException - if user doesn't exist

removeUser

public void removeUser(java.lang.String sessionId,
                       java.lang.String name)
                throws java.rmi.RemoteException
Description copied from interface: Admin
Remove an eXist user account. Requires Admin privilege

Specified by:
removeUser in interface Admin
Parameters:
sessionId - the session identifier
name - the name of the user
Throws:
java.rmi.RemoteException

getUsers

public UserDescs getUsers(java.lang.String sessionId)
                   throws java.rmi.RemoteException
Description copied from interface: Admin
Get an list of users

Specified by:
getUsers in interface Admin
Parameters:
sessionId - the session identifier
Returns:
an array of user infomation (name, groups, home collection)
Throws:
java.rmi.RemoteException

getGroups

public Strings getGroups(java.lang.String sessionId)
                  throws java.rmi.RemoteException
Description copied from interface: Admin
Obtain a list of the defined database groups

Specified by:
getGroups in interface Admin
Parameters:
sessionId - the session identifier
Returns:
the list of groups
Throws:
java.rmi.RemoteException

moveCollection

public void moveCollection(java.lang.String sessionId,
                           java.lang.String collectionPath,
                           java.lang.String destinationPath,
                           java.lang.String newName)
                    throws java.rmi.RemoteException
Description copied from interface: Admin
Move a collection and its contents.

Specified by:
moveCollection in interface Admin
Parameters:
sessionId - the session isentifier
collectionPath - the collection to move
destinationPath - the new parent collection
newName - the new collection name
Throws:
java.rmi.RemoteException

moveResource

public void moveResource(java.lang.String sessionId,
                         java.lang.String docPath,
                         java.lang.String destinationPath,
                         java.lang.String newName)
                  throws java.rmi.RemoteException
Description copied from interface: Admin
Move a resource.

Specified by:
moveResource in interface Admin
Parameters:
sessionId - the session identifier
docPath - the resource to move
destinationPath - the collection to receive the moved resource
newName - the new name for the resource
Throws:
java.rmi.RemoteException

lockResource

public void lockResource(java.lang.String sessionId,
                         java.lang.String path,
                         java.lang.String userName)
                  throws java.rmi.RemoteException
Description copied from interface: Admin
Place a write lock on the specified resource

Specified by:
lockResource in interface Admin
Parameters:
sessionId - the session identifier
path - the path of the resource to lock
userName - the user name of the lock owner
Throws:
java.rmi.RemoteException

unlockResource

public void unlockResource(java.lang.String sessionId,
                           java.lang.String path)
                    throws java.rmi.RemoteException
Description copied from interface: Admin
Release the lock on the specified resource

Specified by:
unlockResource in interface Admin
Parameters:
sessionId - the session identifier
path - path of the resource to unlock
Throws:
java.rmi.RemoteException

hasUserLock

public java.lang.String hasUserLock(java.lang.String sessionId,
                                    java.lang.String path)
                             throws java.rmi.RemoteException
Description copied from interface: Admin
Return the name of the user owning the lock on the specified resource

Specified by:
hasUserLock in interface Admin
Parameters:
sessionId - the session identifier
path - the resource
Returns:
the name of the lock owner or "" if there is no lock
Throws:
java.rmi.RemoteException

getPermissions

public Permissions getPermissions(java.lang.String sessionId,
                                  java.lang.String resource)
                           throws java.rmi.RemoteException
Description copied from interface: Admin
Return the permissions of the specified collection/document

Specified by:
getPermissions in interface Admin
Parameters:
sessionId - the session identifier
resource - the collection or document
Returns:
the permissions (owner, group, access permissions)
Throws:
java.rmi.RemoteException

listCollectionPermissions

public EntityPermissionsList listCollectionPermissions(java.lang.String sessionId,
                                                       java.lang.String name)
                                                throws java.rmi.RemoteException
Description copied from interface: Admin
Return a list of the permissions of the child collections of the specified parent collection

Specified by:
listCollectionPermissions in interface Admin
Parameters:
sessionId - the session identifier
name - the name of the parent collection
Returns:
array containing child collections with their permissions
Throws:
java.rmi.RemoteException

listDocumentPermissions

public EntityPermissionsList listDocumentPermissions(java.lang.String sessionId,
                                                     java.lang.String name)
                                              throws java.rmi.RemoteException
Description copied from interface: Admin
Return a list of the permissions of the child documents of the specified parent collection

Specified by:
listDocumentPermissions in interface Admin
Parameters:
sessionId - the session identifier
name - name of the parent collection
Returns:
array containing documents with their permissions
Throws:
java.rmi.RemoteException

getIndexedElements

public IndexedElements getIndexedElements(java.lang.String sessionId,
                                          java.lang.String collectionName,
                                          boolean inclusive)
                                   throws java.rmi.RemoteException
Description copied from interface: Admin
Return a list of Indexed Elements for a collection

Specified by:
getIndexedElements in interface Admin
Parameters:
sessionId - the session identifier
collectionName - the collection name
inclusive - include sub-collections ?
Returns:
the list of Indexed Elements
Throws:
java.rmi.RemoteException

storeBinary

public void storeBinary(java.lang.String sessionId,
                        byte[] data,
                        java.lang.String path,
                        java.lang.String mimeType,
                        boolean replace)
                 throws java.rmi.RemoteException
Description copied from interface: Admin
Store a binary resource in the database

Specified by:
storeBinary in interface Admin
Parameters:
sessionId - the session identifier
data - the binary data
path - the path for the new resource
mimeType - the mime type for the resource
replace - replace resource if it already exists
Throws:
java.rmi.RemoteException


Copyright (C) Wolfgang Meier. All rights reserved.