org.eclipse.webdav.client
Class WebDAVFactory

java.lang.Object
  extended by org.eclipse.webdav.client.WebDAVFactory
All Implemented Interfaces:
IContextFactory, ILocatorFactory, IDocumentFactory

public class WebDAVFactory
extends Object
implements ILocatorFactory, IContextFactory, IDocumentFactory

Note: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.


Field Summary
static IContextFactory contextFactory
           
static IDocumentFactory documentFactory
           
static ILocatorFactory locatorFactory
           
 
Constructor Summary
WebDAVFactory()
          WebDavFactory constructor comment.
 
Method Summary
 IContext newContext()
          Create a new empty context.
 IContext newContext(IContext baseContext)
          Creates a new context based on the given context.
 Document newDocument()
           
 ILocator newLocator(String resourceURL)
          Returns a locator with the given resource URL that (implicitly) uses the standard way of resolving resource URLs.
 ILocator newLocator(String resourceURL, String label)
          Answer a new resource locator that identifies a particular server resource by it's URL and label.
 QualifiedName newQualifiedName(String qualifier, String localName)
           
 ILocator newStableLocator(String resourceURL)
          Returns a locator given a stable resource URL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

contextFactory

public static IContextFactory contextFactory

documentFactory

public static IDocumentFactory documentFactory

locatorFactory

public static ILocatorFactory locatorFactory
Constructor Detail

WebDAVFactory

public WebDAVFactory()
WebDavFactory constructor comment.

Method Detail

newContext

public IContext newContext()
Description copied from interface: IContextFactory
Create a new empty context.

Specified by:
newContext in interface IContextFactory
Returns:
the new empty Context.

newContext

public IContext newContext(IContext baseContext)
Description copied from interface: IContextFactory
Creates a new context based on the given context.

The newly created context acts like an acetate layer over the base context: any changes made to the new context are confined to that layer and do not affect the base context; but changes to the base context show through to the new context unless masked by another change made to the new context (c.f. properties).

Specified by:
newContext in interface IContextFactory
Parameters:
baseContext - the default values for the new context.
Returns:
the new wrapping Context.

newDocument

public Document newDocument()
Specified by:
newDocument in interface IDocumentFactory

newLocator

public ILocator newLocator(String resourceURL)
Description copied from interface: ILocatorFactory
Returns a locator with the given resource URL that (implicitly) uses the standard way of resolving resource URLs.

Version-unaware clients use this kind of locator exclusively.

Specified by:
newLocator in interface ILocatorFactory
Parameters:
resourceURL - the URL identifier of the resource as a String.

newLocator

public ILocator newLocator(String resourceURL,
                           String label)
Answer a new resource locator that identifies a particular server resource by it's URL and label.

Specified by:
newLocator in interface ILocatorFactory
Parameters:
resourceURL - the URL of the resource.
label - the version label of the resource.
Returns:
the Locator to the resource.

newQualifiedName

public QualifiedName newQualifiedName(String qualifier,
                                      String localName)

newStableLocator

public ILocator newStableLocator(String resourceURL)
Description copied from interface: ILocatorFactory
Returns a locator given a stable resource URL.

This kind of locator is used only by version-aware clients. The stable URL is generated by the server. Clients may reliably store the URL and use it to identify the same resource in subsequent operations. Resources identified by a stable URL cannot be moved but they may be deleted. The stable URL cannot be bound to a different resource by the client or server).

Note that locators with stable URLs cannot have also have a label.

Specified by:
newStableLocator in interface ILocatorFactory
Parameters:
resourceURL - the stable URL to a versioning resource as a String.


Copyright © 2001-2014 JBoss by Red Hat. All Rights Reserved.