SAP |
package com.sybase.sup.sap;
public interface SAPResultChecker
{
/**
*
* @param f - JCO function that has already been executed.
* Use the JCO API to retrieve returned values and determine if the RFC has executed
* successfully.
* @return a single Map.Entry. The boolean "key" value should be set to true if the
* RFC is deemed to have succeeded. Normal result processing will ensue.<P>
* If the String value is not empty/null, that value will be treated as a warning message,
* which will be logged on the server,
* and returned as a warning in transaction logs to the client.<P>
* Set the key value to false if it is deemed the RFC has failed. The String value will
* be thrown in the body of an exception. The error will be logged on the server, and the
* client will receive a transaction log indicating failure, including the string value.
*/
Map.Entry<Boolean, String> checkReturn(JCO.Function f);
}
|
Web service (SOAP) |
package com.sybase.sup.ws.soap;
public interface WSResultChecker
{
/**
* @param is the method for passing a parameter, and does not support setting a
default value.
* @param response – the SOAP Envelope response from a Web service execute.
* Use the SOAP API to retrieve values and determine if the SOAP request
* has executed successfully.
* @return a single Map.Entry. The boolean "key" value should be set to true if the
* SOAP request is deemed to have succeeded. Normal result processing will ensue.<P>
* If the String value is not empty/null, that value will be treated as a warning message,
* which will be logged on the server,
* and returned as a warning in transaction logs to the client.<P>
* Set the key value to false if it is deemed that SOAP has failed. The String value will
* be thrown in the body of an exception. The error will be logged on the server, and the
* client will receive a transaction log indicating failure, including the string value.
*/
Map.Entry<Boolean, String> checkReturn(javax.xml.soap.SOAPEnvelope response);
}
|
RESTful Web service |
package com.sybase.sup.ws.rest;
import java.util.List;
import java.util.Map;
public interface RestResultChecker
{
/**
* REST Result Checker.
*
* @param responseBody HTTP response body.
*
* @param responseHeaders HTTP response headers in the form
* {{header1,value1}, {header2,value2}, ...}.
*
* @param httpStatusCode HTTP status code.
*
* @return Single Map.Entry whose boolean "key" value is true if the
* HTTP request succeeded, after which normal result processing will
* ensue.<P>
*
* If the String value is not empty/null, that value will be treated
* as a warning message which will be logged on the server and returned
* as a warning in the transaction log sent to the client.<P>
*
* Set the key value to false if it is deemed that the service has failed.
* The String value will be thrown in the body of an exception. The error
* will be logged on the server, and the client will receive a transaction
* log indicating failure, including the string value.
**/
Map.Entry<Boolean, String> checkReturn( String responseBody,
List<List<String>> responseHeaders, int httpStatusCode );
}
|