| java.lang.Object com.ibm.webdav.protocol.http.ResourceHTTPStub com.ibm.webdav.protocol.http.CollectionHTTPStub
CollectionHTTPStub | public class CollectionHTTPStub extends ResourceHTTPStub implements IRCollection(Code) | | A CollectionHTTPStub is a ResourceHTTPStub that contains other
resources including other CollectionHTTPStubs. It provides a
concrete, client side implementation of Collection for client/server
communication over HTTP.
author: Jim Amsden <jamsden@us.ibm.com> |
Constructor Summary | |
public | CollectionHTTPStub() | public | CollectionHTTPStub(String url) Construct a CollectionHTTPStub with the given URL. | public | CollectionHTTPStub(String protocol, String host, int port, String file) Create a CollectionHTTPStub from the given URL components.
Parameters: protocol - the protocol to use, http:, rmi:, or iiop: Parameters: host - the name or IP addres of the server host. | public | CollectionHTTPStub(String protocol, String host, String file) Create a CollectionHTTPStub from the given URL components. | public | CollectionHTTPStub(URL url, TargetSelector targetSelector) Construct a CollectionHTTPStub with the given URL. | public | CollectionHTTPStub(URL context, String spec) Construct a CollectionHTTPStub with the given URL specification in the given context.
The resource having
the url may not exist as this constructor does not access the resource from
the server. |
Method Summary | |
public MultiStatus | copy(ResourceContext context, String destinationURL, boolean overwrite, Vector propertiesToCopy, String depth) Lock this resource collection and potentially all its members
based on the given parameters. | public MultiStatus | createCollection(ResourceContext context, Document contents) Actually create the collection in the repository. | public MultiStatus | getProperties(ResourceContext context, PropertyName names, String depth) Get the named properties for this resource and (potentially) its children. | public MultiStatus | getProperties(ResourceContext context, String depth) Get all the properties for this resource and (potentially) its children. | public MultiStatus | getPropertyNames(ResourceContext context, String depth) Get the names of all properties for this resource and (potentially) its children. | public MultiStatus | lock(ResourceContext context, String scope, String type, int timeout, Element owner, String depth) Lock this resource collection and potentially all its members
based on the given parameters. |
CollectionHTTPStub | public CollectionHTTPStub()(Code) | | |
CollectionHTTPStub | public CollectionHTTPStub(String url) throws WebDAVException(Code) | | Construct a CollectionHTTPStub with the given URL. The collection having
the url may not exist as this constructor does not access the resource from
the server. Use exists() or attmept to get the members of the collection to
see if it exists. Other constructors are provided using parameters for the
various parts of the URL. See java.net.URLConnection.
Parameters: url - the URL of the resource. exception: com.ibm.webdav.WebDAVException - |
CollectionHTTPStub | public CollectionHTTPStub(String protocol, String host, int port, String file) throws WebDAVException(Code) | | Create a CollectionHTTPStub from the given URL components.
Parameters: protocol - the protocol to use, http:, rmi:, or iiop: Parameters: host - the name or IP addres of the server host. Using the client host name,or 'localhost' without a port uses local access with no RPC or server required. Parameters: port - the TCP port to use. HTTP uses 80 by default. Parameters: file - the resource URL relative to the server including any query string, etc. exception: com.ibm.webdav.WebDAVException - See Also: URLConnection See Also: com.ibm.webdav.ResourceFactory |
CollectionHTTPStub | public CollectionHTTPStub(String protocol, String host, String file) throws WebDAVException(Code) | | Create a CollectionHTTPStub from the given URL components. This constructor uses the default
HTTP port.
Parameters: protocol - the protocol to use, http:, rmi:, or iiop: Parameters: host - the name or IP addres of the server host. Using the client host name,or 'localhost' without a port uses local access with no RPC or server required. Parameters: file - the resource URL relative to the server including any query string, etc. exception: com.ibm.webdav.WebDAVException - See Also: com.ibm.webdav.ResourceFactory |
CollectionHTTPStub | public CollectionHTTPStub(URL url, TargetSelector targetSelector) throws WebDAVException(Code) | | Construct a CollectionHTTPStub with the given URL. The resource having
the url may not exist as this constructor does not access the resource from
the server. Use exists() or attmept to get the contents of the resource to
see if it exists. Other constructors are provided using parameters for the
various parts of the URL. See java.net.URLConnection for details. A ResourceFactory
may also be used to construct instances of a Resource.
Parameters: url - the URL of the resource. Parameters: targetSelector - the revision target selector for this Collection exception: com.ibm.webdav.WebDAVException - See Also: URLConnection See Also: com.ibm.webdav.ResourceFactory |
CollectionHTTPStub | public CollectionHTTPStub(URL context, String spec) throws WebDAVException(Code) | | Construct a CollectionHTTPStub with the given URL specification in the given context.
The resource having
the url may not exist as this constructor does not access the resource from
the server. Use exists() or attmept to get the contents of the resource to
see if it exists. Other constructors are provided using parameters for the
various parts of the URL. See java.net.URLConnection for details. A ResourceFactory
may also be used to construct instances of a Collection.
Parameters: context - a URL giving the context in which the spec is evaluated Parameters: spec - a URL whose missing parts are provided by the context exception: com.ibm.webdav.WebDAVException - See Also: URLConnection See Also: com.ibm.webdav.ResourceFactory |
copy | public MultiStatus copy(ResourceContext context, String destinationURL, boolean overwrite, Vector propertiesToCopy, String depth) throws WebDAVException(Code) | | Lock this resource collection and potentially all its members
based on the given parameters. This allows control of the lock
scope (exclusive or shared) the lock type (write), owner information, etc.
Parameters: scope - the scope of the lock, exclusive or shared Parameters: type - the type of the lock, currently only write Parameters: depth - - shallow lock only this resource
/** Copy this resource to the destination URL.Partial results are possible, check the returned status for details. Parameters: destinationURL - the destination Parameters: overwrite - true implies overrite the destination if it exists Parameters: propertiesToCopy - a collection of properties that must be copied orthe method will fail. propertiesToCopy may have one of the following values:- null - ignore properties that cannot be copied
- empty collection - all properties must be copied or the method will fail
- a collection of URIs - a list of the properties that must be copiedor the method will fail
the status of the copy operation for each resource copied exception: com.ibm.webdav.WebDAVException -
|
createCollection | public MultiStatus createCollection(ResourceContext context, Document contents) throws WebDAVException(Code) | | Actually create the collection in the repository. The resource indicated
by the URL must not already exist. All ancestors of this URL must already
exist.
Parameters: contents - an XML Document describing the members of this collection, bodiesof members, and properties on the collections or members. Not completely defined inversion 10 of the WebDAV specification Multistatus describing the resultof the operation exception: com.ibm.webdav.WebDAVException - |
getProperties | public MultiStatus getProperties(ResourceContext context, PropertyName names, String depth) throws WebDAVException(Code) | | Get the named properties for this resource and (potentially) its children.
Parameters: names - an arrary of property names to retrieve. Parameters: depth - an indicator for immediate members or recursively all children.- immediateMembers: propeprties of this resource and its immediate children
- allMembers: properties of this resource and recursively all its children
a MultiStatus of PropertyResponses exception: com.ibm.webdav.WebDAVException - |
getProperties | public MultiStatus getProperties(ResourceContext context, String depth) throws WebDAVException(Code) | | Get all the properties for this resource and (potentially) its children.
Parameters: depth - an indicator for immediate members or recursively all children.- thisResource: propeprties of this resource
- immediateMembers: propeprties of this resource and its immediate children
- allMembers: properties of this resource and recursively all its children
a MultiStatus of PropertyResponses exception: com.ibm.webdav.WebDAVException - |
getPropertyNames | public MultiStatus getPropertyNames(ResourceContext context, String depth) throws WebDAVException(Code) | | Get the names of all properties for this resource and (potentially) its children.
Parameters: depth - an indicator for immediate members or recursively all children.- thisResource: propeprties of this resource
- immediateMembers: propeprties of this resource and its immediate children
- allMembers: properties of this resource and recursively all its children
a MultiStatus of PropertyResponses(PropertyValue.value is always null, PropertyValue.status contains the status) exception: com.ibm.webdav.WebDAVException - |
lock | public MultiStatus lock(ResourceContext context, String scope, String type, int timeout, Element owner, String depth) throws WebDAVException(Code) | | Lock this resource collection and potentially all its members
based on the given parameters. This allows control of the lock
scope (exclusive or shared) the lock type (write), owner information, etc.
Parameters: scope - the scope of the lock, exclusive or shared Parameters: type - the type of the lock, currently only write Parameters: depth - - shallow lock only this resource
- deep lock this resource and all its children
Parameters: timeout - the number of seconds before the lock times out or0 for infinite timeout. Parameters: owner - an XML element containing useful information that can beused to identify the owner of the lock. An href to a home page, anemail address, phone number, etc. Can be null if no owner informationis provided. a MultiStatus containing a lockdiscovery property indicatingthe results of the lock operation. exception: com.ibm.webdav.WebDAVException - |
Methods inherited from com.ibm.webdav.protocol.http.ResourceHTTPStub | public void closeContentsOutputStream(ResourceContext context) throws WebDAVException(Code)(Java Doc) public void closeContentsOutputStream(ResourceContext context, String sContentType) throws WebDAVException(Code)(Java Doc) public MultiStatus copy(ResourceContext context, String destinationURL, boolean overwrite, Vector propertiesToCopy) throws WebDAVException(Code)(Java Doc) public MultiStatus delete(ResourceContext context) throws WebDAVException(Code)(Java Doc) public InputStream getContentsInputStream(ResourceContext context) throws WebDAVException(Code)(Java Doc) public OutputStream getContentsOutputStream(ResourceContext context) throws WebDAVException(Code)(Java Doc) public void getMetaInformation(ResourceContext context) throws WebDAVException(Code)(Java Doc) public MultiStatus getProperties(ResourceContext context) throws WebDAVException(Code)(Java Doc) public MultiStatus getProperties(ResourceContext context, PropertyName names) throws WebDAVException(Code)(Java Doc) public MultiStatus getPropertyNames(ResourceContext context) throws WebDAVException(Code)(Java Doc) protected byte[] getResponseEntity() throws WebDAVException(Code)(Java Doc) protected void getResults() throws WebDAVException(Code)(Java Doc) public MultiStatus lock(ResourceContext context, String scope, String type, int timeout, Element owner) throws WebDAVException(Code)(Java Doc) protected MultiStatus lockResponseToMultiStatus() throws WebDAVException(Code)(Java Doc) public MultiStatus move(ResourceContext context, String destinationURL, boolean overwrite, Vector propertiesToMove) throws WebDAVException(Code)(Java Doc) public byte[] performWith(ResourceContext context, String args) throws WebDAVException(Code)(Java Doc) protected void putRequestEntity(byte[] value) throws WebDAVException(Code)(Java Doc) public MultiStatus refreshLock(ResourceContext context, String lockToken, int timeout) throws WebDAVException(Code)(Java Doc) protected MultiStatus responseToMultiStatus() throws WebDAVException(Code)(Java Doc) public MultiStatus setProperties(ResourceContext context, Document updates) throws WebDAVException(Code)(Java Doc) protected void setupRequest(String method) throws WebDAVException(Code)(Java Doc) public MultiStatus unlock(ResourceContext context, String lockToken) throws WebDAVException(Code)(Java Doc)
|
|
|