org.systinet.wasp.dd
Interface Loader


public interface Loader

This interface is responsible for accessing the XML file containing a deployment descriptor.

Since:
4.0
Component:
Core

Method Summary
 java.io.InputStream load(DeploymentDescriptor parentDD, java.lang.String uri)
          Accesses a deployment descriptor on a given location.
 java.lang.String resolve(DeploymentDescriptor parentDD, QName qname)
          Resolves the name of a deployment descriptor to a reachable URI (which will be used in subsequent call to load).
 java.lang.String resolve(DeploymentDescriptor parentDD, java.lang.String uri)
          Resolves the relative URI of a deployment descriptor to an URI understandable in the subsequent call to load(...).
 

Method Detail

resolve

public java.lang.String resolve(DeploymentDescriptor parentDD,
                                QName qname)
Resolves the name of a deployment descriptor to a reachable URI (which will be used in subsequent call to load). If it can not load the deployment descriptor, returns null.

Parameters:
parentDD - the parent deployment descriptor
qname - name of the deployment descriptor being loaded
Returns:
the URI of the dd being loaded or null if nothing is known about a deployment descriptor with given name

resolve

public java.lang.String resolve(DeploymentDescriptor parentDD,
                                java.lang.String uri)
Resolves the relative URI of a deployment descriptor to an URI understandable in the subsequent call to load(...). If the document with this URI can not be loaded, returns null.

Parameters:
parentDD - the parent deployment descriptor
uri - URI relative to parent's URI
Returns:
the URI of the dd being loaded or null if nothing is known about a deployment descriptor with given relative URI

load

public java.io.InputStream load(DeploymentDescriptor parentDD,
                                java.lang.String uri)
                         throws DeploymentException
Accesses a deployment descriptor on a given location. Before calling this function, one of resolve functions had to be called.

Parameters:
parentDD - the parent deployment descriptor
uri - the URI of the dd being loaded
Returns:
non-null input stream for accessing the dd
Throws:
DeploymentException - if something went wrong