Package com.iizix.ws.api
Interface IRESTfulRequestProcessor
public interface IRESTfulRequestProcessor
Interface implemented by a class providing variable input to the Web Service request.- Author:
- Christopher Mindus
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default void
onPostWebServiceRequest(RESTfulRequest request)
Called when all processing has been completed for the Web Service request.void
onWebServiceRequest(RESTfulRequest request)
Called prior to formatting the Web Service request.
Method Detail
onWebServiceRequest
void onWebServiceRequest(RESTfulRequest request) throws java.io.IOException, PropException
Called prior to formatting the Web Service request. This enables e.g. fetching a Token that is used in the request to identify the requestor.For e.g. Microsoft Translator, it is:
tokenRequest = "grant_type=client_credentials&scope=http://api.microsofttranslator.com&client_id=NNN&client_secret=MMM"
It is allowed to set Value's using e.g.
RESTfulInputProps
- Parameters:
request
- The RESTful request transaction.- Throws:
java.io.IOException
- For I/O errors.PropException
- For property errors.
onPostWebServiceRequest
default void onPostWebServiceRequest(RESTfulRequest request) throws java.io.IOException, PropException
Called when all processing has been completed for the Web Service request. This enables e.g. changing the final URI, etc. The default processing is to do nothing.- Parameters:
request
- The RESTful request transaction.- Throws:
java.io.IOException
- For I/O errors.PropException
- For property errors.