@UriEndpoint(firstVersion="2.16.0",
scheme="rest-api",
title="REST API",
syntax="rest-api:path/contextIdPattern",
consumerOnly=true,
label="core,rest",
lenientProperties=true)
public class RestApiEndpoint
extends org.apache.camel.support.DefaultEndpoint
| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_API_COMPONENT_NAME |
static String |
RESOURCE_PATH |
| Constructor and Description |
|---|
RestApiEndpoint(String endpointUri,
RestApiComponent component) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.camel.Consumer |
createConsumer(org.apache.camel.Processor processor) |
org.apache.camel.Producer |
createProducer() |
String |
getApiComponentName() |
RestApiComponent |
getComponent() |
String |
getConsumerComponentName() |
String |
getContextIdPattern() |
Map<String,Object> |
getParameters() |
String |
getPath() |
boolean |
isLenientProperties() |
void |
setApiComponentName(String apiComponentName)
The Camel Rest API component to use for generating the API of the REST services, such as swagger.
|
void |
setConsumerComponentName(String consumerComponentName)
The Camel Rest component to use for (consumer) the REST transport, such as jetty, servlet, undertow.
|
void |
setContextIdPattern(String contextIdPattern)
Optional CamelContext id pattern to only allow Rest APIs from rest services within CamelContext's which name matches the pattern.
|
void |
setParameters(Map<String,Object> parameters)
Additional parameters to configure the consumer of the REST transport for this REST service
|
void |
setPath(String path)
The base path
|
configureConsumer, configurePollingConsumer, configureProperties, createAsyncProducer, createEndpointUri, createExchange, createExchange, createPollingConsumer, doInit, doStart, doStop, equals, getCamelContext, getEndpointKey, getEndpointUri, getExceptionHandler, getExchangePattern, getId, getPollingConsumerBlockTimeout, getPollingConsumerQueueSize, hashCode, isBasicPropertyBinding, isBridgeErrorHandler, isLazyStartProducer, isPollingConsumerBlockWhenFull, isSingleton, isSynchronous, setBasicPropertyBinding, setBridgeErrorHandler, setCamelContext, setEndpointUri, setEndpointUriIfNotSpecified, setExceptionHandler, setExchangePattern, setLazyStartProducer, setPollingConsumerBlockTimeout, setPollingConsumerBlockWhenFull, setPollingConsumerQueueSize, setProperties, setSynchronous, toStringbuild, doBuild, doResume, doShutdown, doSuspend, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspendpublic static final String DEFAULT_API_COMPONENT_NAME
public static final String RESOURCE_PATH
public RestApiEndpoint(String endpointUri, RestApiComponent component)
public RestApiComponent getComponent()
getComponent in class org.apache.camel.support.DefaultEndpointpublic String getPath()
public void setPath(String path)
public String getContextIdPattern()
public void setContextIdPattern(String contextIdPattern)
public String getConsumerComponentName()
public void setConsumerComponentName(String consumerComponentName)
public String getApiComponentName()
public void setApiComponentName(String apiComponentName)
public void setParameters(Map<String,Object> parameters)
public org.apache.camel.Consumer createConsumer(org.apache.camel.Processor processor)
throws Exception
Exceptionpublic boolean isLenientProperties()
isLenientProperties in interface org.apache.camel.EndpointisLenientProperties in class org.apache.camel.support.DefaultEndpointApache Camel