public class ServletComponent
extends org.apache.camel.http.common.HttpCommonComponent
implements org.apache.camel.spi.RestConsumerFactory, org.apache.camel.spi.RestApiConsumerFactory
| Constructor and Description |
|---|
ServletComponent() |
ServletComponent(Class<? extends ServletEndpoint> endpointClass) |
| Modifier and Type | Method and Description |
|---|---|
void |
connect(org.apache.camel.http.common.HttpConsumer consumer) |
org.apache.camel.Consumer |
createApiConsumer(org.apache.camel.CamelContext camelContext,
org.apache.camel.Processor processor,
String contextPath,
org.apache.camel.spi.RestConfiguration configuration,
Map<String,Object> parameters) |
org.apache.camel.Consumer |
createConsumer(org.apache.camel.CamelContext camelContext,
org.apache.camel.Processor processor,
String verb,
String basePath,
String uriTemplate,
String consumes,
String produces,
org.apache.camel.spi.RestConfiguration configuration,
Map<String,Object> parameters) |
protected org.apache.camel.Endpoint |
createEndpoint(String uri,
String remaining,
Map<String,Object> parameters) |
protected ServletEndpoint |
createServletEndpoint(String endpointUri,
ServletComponent component,
URI httpUri)
Strategy to create the servlet endpoint.
|
void |
disconnect(org.apache.camel.http.common.HttpConsumer consumer) |
protected void |
doStart() |
HttpRegistry |
getHttpRegistry() |
String |
getServletName() |
protected boolean |
lenientContextPath()
Whether defining the context-path is lenient and do not require an exact leading slash.
|
void |
setHttpRegistry(HttpRegistry httpRegistry)
To use a custom
HttpRegistry. |
void |
setServletName(String servletName)
Default name of servlet to use.
|
getHttpBinding, getHttpConfiguration, isAllowJavaSerializedObject, setAllowJavaSerializedObject, setHttpBinding, setHttpConfiguration, useIntrospectionOnEndpointgetHeaderFilterStrategy, setEndpointHeaderFilterStrategy, setHeaderFilterStrategycreateComponentConfiguration, createParameterConfigurationMap, getEndpointClass, getParameterConfigurationMap, populateParameterConfigurationMap, setEndpointClassafterConfiguration, createConfiguration, createEndpoint, doStop, getAndRemoveOrResolveReferenceParameter, getAndRemoveOrResolveReferenceParameter, getAndRemoveParameter, getAndRemoveParameter, getCamelContext, ifStartsWithReturnRemainder, preProcessUri, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceParameter, resolveAndRemoveReferenceParameter, setCamelContext, setProperties, useRawUri, validateParameters, validateURIpublic ServletComponent()
public ServletComponent(Class<? extends ServletEndpoint> endpointClass)
protected org.apache.camel.Endpoint createEndpoint(String uri, String remaining, Map<String,Object> parameters) throws Exception
createEndpoint in class org.apache.camel.impl.DefaultComponentExceptionprotected boolean lenientContextPath()
protected ServletEndpoint createServletEndpoint(String endpointUri, ServletComponent component, URI httpUri) throws Exception
Exceptionpublic void connect(org.apache.camel.http.common.HttpConsumer consumer)
throws Exception
connect in class org.apache.camel.http.common.HttpCommonComponentExceptionpublic void disconnect(org.apache.camel.http.common.HttpConsumer consumer)
throws Exception
disconnect in class org.apache.camel.http.common.HttpCommonComponentExceptionpublic String getServletName()
public void setServletName(String servletName)
public HttpRegistry getHttpRegistry()
public void setHttpRegistry(HttpRegistry httpRegistry)
HttpRegistry.public org.apache.camel.Consumer createConsumer(org.apache.camel.CamelContext camelContext,
org.apache.camel.Processor processor,
String verb,
String basePath,
String uriTemplate,
String consumes,
String produces,
org.apache.camel.spi.RestConfiguration configuration,
Map<String,Object> parameters)
throws Exception
createConsumer in interface org.apache.camel.spi.RestConsumerFactoryExceptionpublic org.apache.camel.Consumer createApiConsumer(org.apache.camel.CamelContext camelContext,
org.apache.camel.Processor processor,
String contextPath,
org.apache.camel.spi.RestConfiguration configuration,
Map<String,Object> parameters)
throws Exception
createApiConsumer in interface org.apache.camel.spi.RestApiConsumerFactoryExceptionApache Camel