|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.camel.support.ServiceSupport
org.apache.camel.impl.DefaultEndpoint
org.apache.camel.impl.ScheduledPollEndpoint
org.apache.camel.impl.DefaultPollingEndpoint
org.apache.camel.impl.ProcessorEndpoint
org.apache.camel.component.ResourceEndpoint
org.apache.camel.component.language.LanguageEndpoint
@UriEndpoint(scheme="language") public class LanguageEndpoint
Language endpoint.
| Field Summary |
|---|
| Fields inherited from class org.apache.camel.component.ResourceEndpoint |
|---|
log |
| Fields inherited from class org.apache.camel.support.ServiceSupport |
|---|
shutdown, shuttingdown, started, starting, stopped, stopping, suspended, suspending |
| Constructor Summary | |
|---|---|
LanguageEndpoint()
|
|
LanguageEndpoint(String endpointUri,
Component component,
Language language,
Expression expression,
String resourceUri)
|
|
| Method Summary | |
|---|---|
void |
clearContentCache()
|
Consumer |
createConsumer(Processor processor)
Creates a new Event Driven Consumer which consumes messages from the endpoint using the given processor |
protected String |
createEndpointUri()
A factory method to lazily create the endpointUri if none is specified |
Producer |
createProducer()
Creates a new producer which is used send messages into the endpoint |
Expression |
getExpression()
|
Language |
getLanguage()
|
String |
getScript()
|
boolean |
isCacheScript()
|
boolean |
isContentResolvedFromResource()
|
boolean |
isSingleton()
Whether this class supports being singleton or not. |
boolean |
isTransform()
|
protected String |
resolveScript(String script)
Resolves the script. |
void |
setCacheScript(boolean cacheScript)
Whether to cache the compiled script and reuse Notice reusing the script can cause side effects from processing one Camel Exchange to the next Exchange. |
void |
setContentResolvedFromResource(boolean contentResolvedFromResource)
|
void |
setExpression(Expression expression)
|
void |
setLanguageName(String languageName)
Sets the name of the language to use |
void |
setScript(String script)
Sets the script to execute |
void |
setTransform(boolean transform)
Whether or not the result of the script should be used as message body. |
| Methods inherited from class org.apache.camel.component.ResourceEndpoint |
|---|
getCamelId, getCamelManagementName, getResourceAsInputStream, getResourceAsInputStreamWithoutCache, getResourceUri, getState, isContentCache, isContentCacheCleared, loadResource, setContentCache, setResourceUri |
| Methods inherited from class org.apache.camel.impl.ProcessorEndpoint |
|---|
createPollingConsumer, createProcessor, getProcessor, onExchange, setProcessor |
| Methods inherited from class org.apache.camel.impl.ScheduledPollEndpoint |
|---|
configurePollingConsumer, configureProperties, configureScheduledPollConsumerProperties |
| Methods inherited from class org.apache.camel.support.ServiceSupport |
|---|
doResume, doShutdown, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, resume, shutdown, start, stop, suspend |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.apache.camel.Service |
|---|
start, stop |
| Constructor Detail |
|---|
public LanguageEndpoint()
public LanguageEndpoint(String endpointUri,
Component component,
Language language,
Expression expression,
String resourceUri)
| Method Detail |
|---|
public Producer createProducer()
throws Exception
Endpoint
createProducer in interface EndpointcreateProducer in class ProcessorEndpointException - can be thrown
public Consumer createConsumer(Processor processor)
throws Exception
Endpoint
createConsumer in interface EndpointcreateConsumer in class DefaultPollingEndpointprocessor - the given processor
Exception - can be thrown
protected String resolveScript(String script)
throws IOException
script - script or uri for a script to load
IOException - is thrown if error loading the scriptpublic boolean isSingleton()
IsSingleton
isSingleton in interface IsSingletonisSingleton in class ProcessorEndpointprotected String createEndpointUri()
DefaultEndpoint
createEndpointUri in class DefaultEndpointpublic Language getLanguage()
public Expression getExpression()
public void setExpression(Expression expression)
public boolean isTransform()
public void setTransform(boolean transform)
transform - true to use result as new message body, false to keep the existing message bodypublic void setLanguageName(String languageName)
languageName - the name of the languagepublic void setScript(String script)
script - the scriptpublic String getScript()
public boolean isContentResolvedFromResource()
public void setContentResolvedFromResource(boolean contentResolvedFromResource)
public boolean isCacheScript()
public void setCacheScript(boolean cacheScript)
Exchange to the next Exchange.
public void clearContentCache()
clearContentCache in interface ManagedResourceEndpointMBeanclearContentCache in class ResourceEndpoint
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||