public class RESTActivity extends AbstractAsynchronousActivity<com.fasterxml.jackson.databind.JsonNode>
Modifier and Type | Class and Description |
---|---|
static class |
RESTActivity.DATA_FORMAT |
static class |
RESTActivity.HTTP_METHOD |
Modifier and Type | Field and Description |
---|---|
static String |
IN_BODY |
static String |
OUT_COMPLETE_URL |
static String |
OUT_REDIRECTION |
static String |
OUT_RESPONSE_BODY |
static String |
OUT_RESPONSE_HEADERS |
static String |
OUT_STATUS |
static String |
URI |
inputPortMapping, inputPorts, outputPortMapping, outputPorts
Constructor and Description |
---|
RESTActivity(org.apache.http.client.CredentialsProvider credentialsProvider) |
Modifier and Type | Method and Description |
---|---|
void |
configure(com.fasterxml.jackson.databind.JsonNode json) |
protected void |
configurePorts() |
void |
executeAsynch(Map<String,T2Reference> inputs,
AsynchronousActivityCallback callback)
This method executes pre-configured instance of REST activity.
|
com.fasterxml.jackson.databind.JsonNode |
getConfiguration() |
RESTActivityConfigurationBean |
getConfigurationBean() |
boolean |
hasMessageBodyInputPort()
Uses HTTP method value of the config bean of the current instance of
RESTActivity.
|
static boolean |
hasMessageBodyInputPort(RESTActivity.HTTP_METHOD httpMethod)
Return value of this method has a number of implications - various input
ports and configuration options for this activity are applied based on
the selected HTTP method.
|
addInput, addOutput, addOutput, configurePorts, getEdits, getInputPortMapping, getInputPorts, getOutputPortMapping, getOutputPorts, removeInputs, removeOutputs, setEdits
getAddAnnotationEdit, getAnnotations, getRemoveAnnotationEdit, setAnnotations
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getInputPortMapping, getInputPorts, getOutputPortMapping, getOutputPorts, setEdits
getAddAnnotationEdit, getAnnotations, getRemoveAnnotationEdit, setAnnotations
public static final String URI
public static final String IN_BODY
public static final String OUT_RESPONSE_BODY
public static final String OUT_RESPONSE_HEADERS
public static final String OUT_STATUS
public static final String OUT_REDIRECTION
public static final String OUT_COMPLETE_URL
public RESTActivity(org.apache.http.client.CredentialsProvider credentialsProvider)
public com.fasterxml.jackson.databind.JsonNode getConfiguration()
getConfiguration
in interface Configurable<com.fasterxml.jackson.databind.JsonNode>
getConfiguration
in class AbstractAsynchronousActivity<com.fasterxml.jackson.databind.JsonNode>
public RESTActivityConfigurationBean getConfigurationBean()
public void configure(com.fasterxml.jackson.databind.JsonNode json) throws ActivityConfigurationException
configure
in interface Configurable<com.fasterxml.jackson.databind.JsonNode>
configure
in interface Activity<com.fasterxml.jackson.databind.JsonNode>
configure
in class AbstractAsynchronousActivity<com.fasterxml.jackson.databind.JsonNode>
ActivityConfigurationException
protected void configurePorts()
public boolean hasMessageBodyInputPort()
hasMessageBodyInputPort(HTTP_METHOD)
public static boolean hasMessageBodyInputPort(RESTActivity.HTTP_METHOD httpMethod)
httpMethod
- HTTP method to make the decision for.public void executeAsynch(Map<String,T2Reference> inputs, AsynchronousActivityCallback callback)
HTTPRequestHandler#initiateHTTPRequest(String, RESTActivityConfigurationBean, String)
.executeAsynch
in interface AsynchronousActivity<com.fasterxml.jackson.databind.JsonNode>
executeAsynch
in class AbstractAsynchronousActivity<com.fasterxml.jackson.databind.JsonNode>
Copyright © 2015–2016 The Apache Software Foundation. All rights reserved.