org.apache.tuscany.sca.implementation.bpel.xml
Class BPELDocumentProcessor

java.lang.Object
  extended by org.apache.tuscany.sca.contribution.processor.BaseStAXArtifactProcessor
      extended by org.apache.tuscany.sca.implementation.bpel.xml.BPELDocumentProcessor
All Implemented Interfaces:
ArtifactProcessor<BPELProcessDefinition>, URLArtifactProcessor<BPELProcessDefinition>

public class BPELDocumentProcessor
extends BaseStAXArtifactProcessor
implements URLArtifactProcessor<BPELProcessDefinition>

BPEL document processor responsible for reading a BPEL file and producing necessary model info about it TODO: The namespaces for WS-BPEL include 2 versions - only the earlier BPEL 1.1 versions are supported at present - the BPEL 2.0 namespaces also need support. This will require inspection of both BPEL process files and of WSDL files for their BPEL namespaces


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.tuscany.sca.contribution.processor.BaseStAXArtifactProcessor
BaseStAXArtifactProcessor.XAttr
 
Field Summary
static javax.xml.namespace.QName BPEL_EXECUTABLE_DEFINITION
           
static javax.xml.namespace.QName BPEL_PROCESS_DEFINITION
           
static java.lang.String NAME_ELEMENT
           
 
Constructor Summary
BPELDocumentProcessor(ModelFactoryExtensionPoint modelFactories, Monitor monitor)
           
 
Method Summary
 java.lang.String getArtifactType()
          Returns the type of artifact handled by this artifact processor.
 java.lang.Class<BPELProcessDefinition> getModelType()
          Returns the type of model handled by this artifact processor.
 BPELProcessDefinition read(java.net.URL contributionURL, java.net.URI artifactURI, java.net.URL artifactURL)
          Reads a model from a URL.
 void resolve(BPELProcessDefinition model, ModelResolver resolver)
          Resolve references from this model to other models.
 
Methods inherited from class org.apache.tuscany.sca.contribution.processor.BaseStAXArtifactProcessor
getBoolean, getQName, getQNames, getQNameValue, getString, getXSIType, isSet, nextChildElement, skipToEndElement, writeAttributePrefixes, writeAttributes, writeEnd, writeEndDocument, writeStart, writeStart, writeStartDocument, writeStartDocument
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BPEL_PROCESS_DEFINITION

public static final javax.xml.namespace.QName BPEL_PROCESS_DEFINITION

BPEL_EXECUTABLE_DEFINITION

public static final javax.xml.namespace.QName BPEL_EXECUTABLE_DEFINITION

NAME_ELEMENT

public static final java.lang.String NAME_ELEMENT
See Also:
Constant Field Values
Constructor Detail

BPELDocumentProcessor

public BPELDocumentProcessor(ModelFactoryExtensionPoint modelFactories,
                             Monitor monitor)
Method Detail

getArtifactType

public java.lang.String getArtifactType()
Description copied from interface: URLArtifactProcessor
Returns the type of artifact handled by this artifact processor.

Specified by:
getArtifactType in interface URLArtifactProcessor<BPELProcessDefinition>
Returns:
The type of artifact handled by this artifact processor

getModelType

public java.lang.Class<BPELProcessDefinition> getModelType()
Description copied from interface: ArtifactProcessor
Returns the type of model handled by this artifact processor.

Specified by:
getModelType in interface ArtifactProcessor<BPELProcessDefinition>
Returns:
The type of model handled by this artifact processor

read

public BPELProcessDefinition read(java.net.URL contributionURL,
                                  java.net.URI artifactURI,
                                  java.net.URL artifactURL)
                           throws ContributionReadException
Description copied from interface: URLArtifactProcessor
Reads a model from a URL.

Specified by:
read in interface URLArtifactProcessor<BPELProcessDefinition>
Parameters:
contributionURL - Contribution location URL
artifactURI - Artifact URI
artifactURL - Artifact location URL
Returns:
A model representation of the input.
Throws:
ContributionReadException

resolve

public void resolve(BPELProcessDefinition model,
                    ModelResolver resolver)
             throws ContributionResolveException
Description copied from interface: ArtifactProcessor
Resolve references from this model to other models. For example references from a composite to another one, or references from a composite to a WSDL model.

Specified by:
resolve in interface ArtifactProcessor<BPELProcessDefinition>
Parameters:
model - The model to resolve
resolver - The resolver to use to resolve referenced models
Throws:
ContributionResolveException