Inherits Module.
List of all members.
Public Member Functions |
| WebserviceModule (Map< String, ModelPublishedService > publishedServices, Collection< ModelImportedService > wsdlFiles) throws Exception |
List< UserActionListener<?> > | getActionListeners () |
List< ClientAction > | getClientActions () |
List< String > | getUserActionNames () |
void | handleWebserviceCall (IMxRuntimeRequest request, IMxRuntimeResponse response, String path) |
void | handleWebserviceDocCall (IMxRuntimeRequest request, IMxRuntimeResponse response, String path) |
String | getWebserviceHandlerURL (IMxRuntimeRequest request) |
Static Public Member Functions |
static IWebserviceResponse | callWebservice (String location, String soapAction, RequestInfo requestInfo) throws WebserviceException, IOException |
static IWebserviceResponse | callWebservice (String location, String soapAction, InputStream soapRequestMessage) throws WebserviceException, IOException |
static IWebserviceResponse | callWebservice (String location, String soapAction, String soapRequestMessage) throws WebserviceException, IOException |
Static Public Attributes |
static final File | WSDL_FILES_LOCATION = new File(Core.getConfiguration().getBasePath(), "model/wsdls/") |
Detailed Description
Entry point for web service handling (calling web services and handling published web service calls). Custom Java actions can use this class for calling web services which need custom SOAP messages (by using WebserviceModule#callWebservice(String, String, InputStream) or WebserviceModule#callWebservice(String, String, String)). Custom handling of web service responses can be performed by manual processing of IWebserviceResponse#IWebServiceResponse.getStream(). Mapping defined in the Modeler can be used to map an IWebserviceResponse stream using Core#importXmlStream(IContext, InputStream, String, IMendixObject).
Constructor & Destructor Documentation
com.mendix.modules.webservices.WebserviceModule.WebserviceModule |
( |
Map< String, ModelPublishedService > |
publishedServices, |
|
|
Collection< ModelImportedService > |
wsdlFiles |
|
) |
| throws Exception |
- Parameters:
-
publishedServices | |
wsdlFiles | |
- Exceptions:
-
Member Function Documentation
static IWebserviceResponse com.mendix.modules.webservices.WebserviceModule.callWebservice |
( |
String |
location, |
|
|
String |
soapAction, |
|
|
RequestInfo |
requestInfo |
|
) |
| throws WebserviceException, IOException [static] |
Call a webservice Post method headers:
- Content-Type: text/xml
- Host: location host (e.g. www.w3schools.com)
- SoapAction: soapAction (e.g. http://tempuri.com/FahrenheitToCelsius)
- Parameters:
-
location | the webservice location url |
soapAction | the webservice soap action |
requestInfo |
<?xml version="1.0" encoding="utf-8"?>
<soap:envelope
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>
<soap:header>
<authentication>
<username> username </username>
<password> password </password>
</authentication>
</soap:header>
<soap:body>
<operationName xmlns:=targetNamespace>
<x>5</x>
<y>5.0</y>
</operationName>
</soap:body>
</soap:envelope>
|
- Returns:
- a soap envelope response stream, e.g.:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
>
<soap:Body>
<OperationResponse xmlns=namespace>
<Result>string</Result>
</OperationResponse>
</soap:Body>
</soap:Envelope>
- Exceptions:
-
static IWebserviceResponse com.mendix.modules.webservices.WebserviceModule.callWebservice |
( |
String |
location, |
|
|
String |
soapAction, |
|
|
InputStream |
soapRequestMessage |
|
) |
| throws WebserviceException, IOException [static] |
Call a webservice Post method headers:
- Content-Type: text/xml
- Host: location host (e.g. www.w3schools.com)
- SoapAction: soapAction (e.g. http://tempuri.com/FahrenheitToCelsius)
- Parameters:
-
location | the webservice location url |
soapAction | the webservice soap action |
soapRequestMessage |
<?xml version="1.0" encoding="utf-8"?>
<soap:envelope
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>
<soap:header>
<authentication>
<username> username </username>
<password> password </password>
</authentication>
</soap:header>
<soap:body>
<operationName xmlns:=targetNamespace>
<x>5</x>
<y>5.0</y>
</operationName>
</soap:body>
</soap:envelope>
|
- Returns:
- a soap envelope response stream, e.g.:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
>
<soap:Body>
<OperationResponse xmlns=namespace>
<Result>string</Result>
</OperationResponse>
</soap:Body>
</soap:Envelope>
- Exceptions:
-
static IWebserviceResponse com.mendix.modules.webservices.WebserviceModule.callWebservice |
( |
String |
location, |
|
|
String |
soapAction, |
|
|
String |
soapRequestMessage |
|
) |
| throws WebserviceException, IOException [static] |
Call a webservice Post method headers:
- Content-Type: text/xml
- Host: location host (e.g. www.w3schools.com)
- SoapAction: soapAction (e.g. http://tempuri.com/FahrenheitToCelsius)
- Parameters:
-
location | the webservice location url |
soapAction | the webservice soap action |
soapRequestMessage |
<?xml version="1.0" encoding="utf-8"?>
<soap:envelope
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>
<soap:header>
<authentication>
<username> username </username>
<password> password </password>
</authentication>
</soap:header>
<soap:body>
<operationName xmlns:=targetNamespace>
<x>5</x>
<y>5.0</y>
</operationName>
</soap:body>
</soap:envelope>
|
- Returns:
- a soap envelope response stream, e.g.:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
>
<soap:Body>
<OperationResponse xmlns=namespace>
<Result>string</Result>
</OperationResponse>
</soap:Body>
</soap:Envelope>
- Exceptions:
-
List<UserActionListener<?> > com.mendix.modules.webservices.WebserviceModule.getActionListeners |
( |
| ) |
|
- Returns:
- the actionlisteners
List<ClientAction> com.mendix.modules.webservices.WebserviceModule.getClientActions |
( |
| ) |
|
- Returns:
- the clientactions
List<String> com.mendix.modules.webservices.WebserviceModule.getUserActionNames |
( |
| ) |
|
- Returns:
- the user action names
String com.mendix.modules.webservices.WebserviceModule.getWebserviceHandlerURL |
( |
IMxRuntimeRequest |
request | ) |
|
- Parameters:
-
- Returns:
- the webservice handler url
void com.mendix.modules.webservices.WebserviceModule.handleWebserviceCall |
( |
IMxRuntimeRequest |
request, |
|
|
IMxRuntimeResponse |
response, |
|
|
String |
path |
|
) |
| |
void com.mendix.modules.webservices.WebserviceModule.handleWebserviceDocCall |
( |
IMxRuntimeRequest |
request, |
|
|
IMxRuntimeResponse |
response, |
|
|
String |
path |
|
) |
| |
Member Data Documentation
The documentation for this class was generated from the following file: