org.ow2.petals.component.framework.api.util
Interface WSDLUtil


public interface WSDLUtil

Contains utilities for the WSDL management.

Author:
Frederic Gardes

Method Summary
 Document convertDescriptionToDocument(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
          Convert the description to a document
 void convertDescriptionToFile(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description description, File wsdlFile)
          Write a description into a file.
 String convertDescriptionToString(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
          Convert the description to a string
 org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description convertDocumentToDescription(Document document)
          COnvert a document to a description
 org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createLightWSDL20Description(QName interfaceQName, QName serviceQName, String endpointName)
          Create a light WSDL2.0 description from the given ServiceEndpoint.
 org.ow2.easywsdl.wsdl.api.Endpoint createWSDL20Endpoint(javax.jbi.servicedesc.ServiceEndpoint serviceEndpoint)
          Create a WSDL2.0 enpoint from the given ServiceEndpoint.
 org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation)
          Create a wsdl description.
 org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation, boolean processAutogenerateEndpoint)
          Create a wsdl description.
 org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation, boolean processAutogenerateEndpoint, boolean addImportedDocumentsInWsdl)
          Create a wsdl description.
 List<org.ow2.easywsdl.wsdl.api.Endpoint> getEndpointList(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
          Get the endpoints into a wsdl description.
 List<org.ow2.easywsdl.wsdl.api.Endpoint> getEndpointList(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription, QName serviceQNameFilter, String endpointNameFilter)
          Get the endpoints into a wsdl description.
 boolean isDescriptionContaining(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription, javax.jbi.servicedesc.ServiceEndpoint endpoint)
          Check if a description contains a specific endpoint
 

Method Detail

convertDescriptionToDocument

Document convertDescriptionToDocument(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
                                      throws org.ow2.easywsdl.wsdl.api.WSDLException
Convert the description to a document

Parameters:
wsdlDescription - the description
Returns:
the document
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

convertDescriptionToFile

void convertDescriptionToFile(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description description,
                              File wsdlFile)
                              throws org.ow2.easywsdl.wsdl.api.WSDLException
Write a description into a file.

Parameters:
description - the wsdl description
wsdlFile - The location of the destination wsdl file.
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

convertDescriptionToString

String convertDescriptionToString(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
                                  throws org.ow2.easywsdl.wsdl.api.WSDLException
Convert the description to a string

Parameters:
wsdlDescription - the description
Returns:
the string
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

convertDocumentToDescription

org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description convertDocumentToDescription(Document document)
                                                                                          throws org.ow2.easywsdl.wsdl.api.WSDLException
COnvert a document to a description

Parameters:
document -
Returns:
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

createLightWSDL20Description

org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createLightWSDL20Description(QName interfaceQName,
                                                                                          QName serviceQName,
                                                                                          String endpointName)
                                                                                          throws org.ow2.easywsdl.wsdl.api.WSDLException
Create a light WSDL2.0 description from the given ServiceEndpoint. All attributes are required into the function parameter, otherwise a NullPointerException will be thrown. Namespaces are managed.

Parameters:
interfaceQName - must be non null
serviceQName - must be non null
endpointName - must be non null
Returns:
a WSDL2.0 light description
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException
See Also:
org.ow2.petals.component.framework.util#createLightWSDL20Description( final QName[], final QName, final String)

createWSDL20Endpoint

org.ow2.easywsdl.wsdl.api.Endpoint createWSDL20Endpoint(javax.jbi.servicedesc.ServiceEndpoint serviceEndpoint)
                                                        throws org.ow2.easywsdl.wsdl.api.WSDLException
Create a WSDL2.0 enpoint from the given ServiceEndpoint. All attributes are required into the function parameter, otherwise a NullPointerException will be thrown. Namespaces are managed.

Parameters:
serviceEndpoint - must be non null and must contain non-null attributes
Returns:
a WSDL 2.0 endpoint
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException
See Also:
org.ow2.petals.component.framework.util#createLightWSDL20Description( final QName[], final QName, final String)

createWsdlDescription

org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation)
                                                                                   throws org.ow2.easywsdl.wsdl.api.WSDLException
Create a wsdl description.
NOTE : Imported document are written in the description.

Parameters:
wsdlLocation - the location of the wsdl file
Returns:
the description of the document
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

createWsdlDescription

org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation,
                                                                                   boolean processAutogenerateEndpoint)
                                                                                   throws org.ow2.easywsdl.wsdl.api.WSDLException
Create a wsdl description.
NOTE : Imported document are written in the description.

Parameters:
wsdlLocation - the location of the wsdl file
processAutogenerateEndpoint - true if you want to replace the endpoints named Constants.Component#AUTOGENERATED_ENDPOINT_NAME
by a name generated by PEtALS
Returns:
the description of the document
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

createWsdlDescription

org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description createWsdlDescription(URL wsdlLocation,
                                                                                   boolean processAutogenerateEndpoint,
                                                                                   boolean addImportedDocumentsInWsdl)
                                                                                   throws org.ow2.easywsdl.wsdl.api.WSDLException
Create a wsdl description.

Parameters:
wsdlLocation - the location of the wsdl file
processAutogenerateEndpoint - true if you want to replace the endpoints named Constants.Component#AUTOGENERATED_ENDPOINT_NAME
by a name generated by PEtALS
addImportedDocumentsInWsdl - if true the imported document are written in the description.
Returns:
the description of the document
Throws:
org.ow2.easywsdl.wsdl.api.WSDLException

getEndpointList

List<org.ow2.easywsdl.wsdl.api.Endpoint> getEndpointList(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription)
Get the endpoints into a wsdl description.

Parameters:
wsdlDescription - the wsdl description generated by easy wsdl
Returns:
The list of Endpoint, or null if the description is null

getEndpointList

List<org.ow2.easywsdl.wsdl.api.Endpoint> getEndpointList(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription,
                                                         QName serviceQNameFilter,
                                                         String endpointNameFilter)
Get the endpoints into a wsdl description. Retrieve all of them if no filter name is provided.
Retrieve only the endpoints matching the service QName filter if provided.
Retrieve only the endpoints matching the endpoint name filter if provided.

Parameters:
wsdlDescription - the wsdl description generated by easy wsdl
serviceQNameFilter - if not null, only the endpoints with this service QName will be return
endpointNameFilter - if not null, only the endpoints with this name will be return
Returns:
The list of endpoints, empty if nothing found

isDescriptionContaining

boolean isDescriptionContaining(org.ow2.easywsdl.extensions.wsdl4complexwsdl.api.Description wsdlDescription,
                                javax.jbi.servicedesc.ServiceEndpoint endpoint)
Check if a description contains a specific endpoint

Parameters:
wsdlDescription - the description
endpoint - the endpoint. must be non null, with a service non null and a name non null
Returns:
true if the description contains the endpoint, false else


Copyright © 2005-2012 Petals Link (EBM Websourcing). All Rights Reserved.