org.apache.cxf.frontend
Class WSDLGetUtils

java.lang.Object
  extended by org.apache.cxf.frontend.WSDLGetUtils

public class WSDLGetUtils
extends Object


Field Summary
static String AUTO_REWRITE_ADDRESS
           
static String AUTO_REWRITE_ADDRESS_ALL
           
static String PUBLISHED_ENDPOINT_URL
           
static String WSDL_CREATE_IMPORTS
           
 
Constructor Summary
WSDLGetUtils()
           
 
Method Summary
 Document getDocument(org.apache.cxf.message.Message message, String base, Map<String,String> params, String ctxUri, org.apache.cxf.service.model.EndpointInfo endpointInfo)
           
 String getPublishableEndpointUrl(javax.wsdl.Definition def, String epurl, org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Retrieve the published endpoint url from the working information set.
protected  String getPublishedEndpointURL(org.apache.cxf.message.Message message, String base, org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Retrieve the published endpoint url from the working information set.
protected  Map<String,javax.wsdl.extensions.schema.SchemaReference> getSchemaKeySchemaReference(org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Retrieve the map of known xsd SchemaReference objects for this endpoint.
 Map<String,String> getSchemaLocations(org.apache.cxf.message.Message message, String base, String ctxUri, org.apache.cxf.service.model.EndpointInfo endpointInfo)
           
 Set<String> getWSDLIds(org.apache.cxf.message.Message message, String base, String ctxUri, org.apache.cxf.service.model.EndpointInfo endpointInfo)
           
protected  Map<String,javax.wsdl.Definition> getWSDLKeyDefinition(org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Retrieve the map of known wsdl Definition objects for this endpoint.
protected  String mapUri(String base, Map<String,javax.wsdl.extensions.schema.SchemaReference> smp, String loc, String xsd)
           
protected  Document readXSDDocument(org.apache.cxf.Bus bus, String xsd, Map<String,javax.wsdl.extensions.schema.SchemaReference> smp, String base)
          Read the schema file and return as a Document object.
protected  String resolveWithCatalogs(org.apache.cxf.catalog.OASISCatalogManager catalogs, String start, String base)
           
protected  void rewriteAddress(String base, Element el, String soapNS)
           
protected  void rewriteAddressProtocolHostPort(String base, Element el, String httpBasePathProp, String soapNS)
           
protected  void setSoapAddressLocationOn(javax.wsdl.Port port, String url)
           
protected  void updateDefinition(org.apache.cxf.Bus bus, javax.wsdl.Definition def, Map<String,javax.wsdl.Definition> done, Map<String,javax.wsdl.extensions.schema.SchemaReference> doneSchemas, String base, String docBase)
           
protected  void updateDoc(Document doc, String base, Map<String,javax.wsdl.Definition> mp, Map<String,javax.wsdl.extensions.schema.SchemaReference> smp, org.apache.cxf.message.Message message, String xsd, String wsdl)
           
protected  void updatePublishedEndpointUrl(String publishingUrl, javax.wsdl.Definition def, QName name)
           
protected  void updateSchemaImports(org.apache.cxf.Bus bus, javax.wsdl.extensions.schema.Schema schema, String docBase, Map<String,javax.wsdl.extensions.schema.SchemaReference> doneSchemas, String base)
           
protected  void updateWSDLKeyDefinition(org.apache.cxf.Bus bus, Map<String,javax.wsdl.Definition> mp, org.apache.cxf.message.Message message, Map<String,javax.wsdl.extensions.schema.SchemaReference> smp, String base, org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Create a wsdl Definition object from the endpoint information and register it in the local data structure for future reference.
 void updateWSDLPublishedEndpointAddress(javax.wsdl.Definition def, org.apache.cxf.service.model.EndpointInfo endpointInfo)
           
 Document writeWSDLDocument(org.apache.cxf.message.Message message, Map<String,javax.wsdl.Definition> mp, Map<String,javax.wsdl.extensions.schema.SchemaReference> smp, String wsdl, String base, org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Write the contents of a wsdl Definition object to a file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

AUTO_REWRITE_ADDRESS

public static final String AUTO_REWRITE_ADDRESS
See Also:
Constant Field Values

AUTO_REWRITE_ADDRESS_ALL

public static final String AUTO_REWRITE_ADDRESS_ALL
See Also:
Constant Field Values

PUBLISHED_ENDPOINT_URL

public static final String PUBLISHED_ENDPOINT_URL
See Also:
Constant Field Values

WSDL_CREATE_IMPORTS

public static final String WSDL_CREATE_IMPORTS
See Also:
Constant Field Values
Constructor Detail

WSDLGetUtils

public WSDLGetUtils()
Method Detail

getWSDLIds

public Set<String> getWSDLIds(org.apache.cxf.message.Message message,
                              String base,
                              String ctxUri,
                              org.apache.cxf.service.model.EndpointInfo endpointInfo)

getSchemaLocations

public Map<String,String> getSchemaLocations(org.apache.cxf.message.Message message,
                                             String base,
                                             String ctxUri,
                                             org.apache.cxf.service.model.EndpointInfo endpointInfo)

getDocument

public Document getDocument(org.apache.cxf.message.Message message,
                            String base,
                            Map<String,String> params,
                            String ctxUri,
                            org.apache.cxf.service.model.EndpointInfo endpointInfo)

mapUri

protected String mapUri(String base,
                        Map<String,javax.wsdl.extensions.schema.SchemaReference> smp,
                        String loc,
                        String xsd)
                 throws UnsupportedEncodingException
Throws:
UnsupportedEncodingException

updateDoc

protected void updateDoc(Document doc,
                         String base,
                         Map<String,javax.wsdl.Definition> mp,
                         Map<String,javax.wsdl.extensions.schema.SchemaReference> smp,
                         org.apache.cxf.message.Message message,
                         String xsd,
                         String wsdl)

rewriteAddress

protected void rewriteAddress(String base,
                              Element el,
                              String soapNS)

rewriteAddressProtocolHostPort

protected void rewriteAddressProtocolHostPort(String base,
                                              Element el,
                                              String httpBasePathProp,
                                              String soapNS)

resolveWithCatalogs

protected String resolveWithCatalogs(org.apache.cxf.catalog.OASISCatalogManager catalogs,
                                     String start,
                                     String base)

updateDefinition

protected void updateDefinition(org.apache.cxf.Bus bus,
                                javax.wsdl.Definition def,
                                Map<String,javax.wsdl.Definition> done,
                                Map<String,javax.wsdl.extensions.schema.SchemaReference> doneSchemas,
                                String base,
                                String docBase)

updateWSDLPublishedEndpointAddress

public void updateWSDLPublishedEndpointAddress(javax.wsdl.Definition def,
                                               org.apache.cxf.service.model.EndpointInfo endpointInfo)

updatePublishedEndpointUrl

protected void updatePublishedEndpointUrl(String publishingUrl,
                                          javax.wsdl.Definition def,
                                          QName name)

setSoapAddressLocationOn

protected void setSoapAddressLocationOn(javax.wsdl.Port port,
                                        String url)

updateSchemaImports

protected void updateSchemaImports(org.apache.cxf.Bus bus,
                                   javax.wsdl.extensions.schema.Schema schema,
                                   String docBase,
                                   Map<String,javax.wsdl.extensions.schema.SchemaReference> doneSchemas,
                                   String base)

writeWSDLDocument

public Document writeWSDLDocument(org.apache.cxf.message.Message message,
                                  Map<String,javax.wsdl.Definition> mp,
                                  Map<String,javax.wsdl.extensions.schema.SchemaReference> smp,
                                  String wsdl,
                                  String base,
                                  org.apache.cxf.service.model.EndpointInfo endpointInfo)
                           throws javax.wsdl.WSDLException
Write the contents of a wsdl Definition object to a file.

Parameters:
message -
mp - a map of known wsdl Definition objects
smp - a map of known xsd SchemaReference objects
wsdl - name of the wsdl file to write
base - the request URL
endpointInfo - information for a web service 'port' inside of a service
Returns:
Document
Throws:
javax.wsdl.WSDLException

getPublishableEndpointUrl

public String getPublishableEndpointUrl(javax.wsdl.Definition def,
                                        String epurl,
                                        org.apache.cxf.service.model.EndpointInfo endpointInfo)
Retrieve the published endpoint url from the working information set.

Parameters:
def - a wsdl as class objects
epurl - the request URL
endpointInfo - information for a web service 'port' inside of a service
Returns:
String

readXSDDocument

protected Document readXSDDocument(org.apache.cxf.Bus bus,
                                   String xsd,
                                   Map<String,javax.wsdl.extensions.schema.SchemaReference> smp,
                                   String base)
                            throws XMLStreamException
Read the schema file and return as a Document object.

Parameters:
bus - CXF's hub for access to internal constructs
xsd - name of xsd file to be read
smp - a map of known xsd SchemaReference objects
base - the request URL
Returns:
Document
Throws:
XMLStreamException

updateWSDLKeyDefinition

protected void updateWSDLKeyDefinition(org.apache.cxf.Bus bus,
                                       Map<String,javax.wsdl.Definition> mp,
                                       org.apache.cxf.message.Message message,
                                       Map<String,javax.wsdl.extensions.schema.SchemaReference> smp,
                                       String base,
                                       org.apache.cxf.service.model.EndpointInfo endpointInfo)
                                throws javax.wsdl.WSDLException
Create a wsdl Definition object from the endpoint information and register it in the local data structure for future reference.

Parameters:
bus - CXF's hub for access to internal constructs
mp - a map of known wsdl Definition objects
message -
smp - a map of known xsd SchemaReference objects
base - the request URL
endpointInfo - information for a web service 'port' inside of a service
Throws:
javax.wsdl.WSDLException

getSchemaKeySchemaReference

protected Map<String,javax.wsdl.extensions.schema.SchemaReference> getSchemaKeySchemaReference(org.apache.cxf.service.model.EndpointInfo endpointInfo)
Retrieve the map of known xsd SchemaReference objects for this endpoint.

Parameters:
endpointInfo - information for a web service 'port' inside of a service
Returns:
Map

getWSDLKeyDefinition

protected Map<String,javax.wsdl.Definition> getWSDLKeyDefinition(org.apache.cxf.service.model.EndpointInfo endpointInfo)
Retrieve the map of known wsdl Definition objects for this endpoint.

Parameters:
endpointInfo - information for a web service 'port' inside of a service
Returns:
Map

getPublishedEndpointURL

protected String getPublishedEndpointURL(org.apache.cxf.message.Message message,
                                         String base,
                                         org.apache.cxf.service.model.EndpointInfo endpointInfo)
Retrieve the published endpoint url from the working information set.

Parameters:
message -
base - the request URL
endpointInfo - information for a web service 'port' inside of a service
Returns:
String or NULL if none found


Apache CXF