public abstract class FeedEndpoint
extends org.apache.camel.support.DefaultPollingEndpoint
| Modifier and Type | Field and Description |
|---|---|
protected String |
feedUri |
protected boolean |
filter |
protected Date |
lastUpdate |
protected boolean |
splitEntries |
| Constructor and Description |
|---|
FeedEndpoint() |
FeedEndpoint(String endpointUri,
FeedComponent component,
String feedUri) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.camel.Consumer |
createConsumer(org.apache.camel.Processor processor) |
protected String |
createEndpointUri() |
protected abstract FeedPollingConsumer |
createEntryPollingConsumer(FeedEndpoint feedEndpoint,
org.apache.camel.Processor processor,
boolean filter,
Date lastUpdate,
boolean throttleEntries) |
abstract org.apache.camel.Exchange |
createExchange(Object feed)
Creates an Exchange with the entries as the in body.
|
abstract org.apache.camel.Exchange |
createExchange(Object feed,
Object entry)
Creates an Exchange with the given entry as the in body.
|
protected org.apache.camel.Exchange |
createExchangeWithFeedHeader(Object feed,
String header) |
protected abstract FeedPollingConsumer |
createPollingConsumer(FeedEndpoint feedEndpoint,
org.apache.camel.Processor processor) |
org.apache.camel.Producer |
createProducer() |
String |
getEndpointKey() |
String |
getFeedUri() |
Date |
getLastUpdate() |
String |
getPassword() |
String |
getUsername() |
boolean |
isFeedHeader() |
boolean |
isFilter() |
boolean |
isLenientProperties() |
boolean |
isSortEntries() |
boolean |
isSplitEntries() |
boolean |
isThrottleEntries() |
void |
setFeedHeader(boolean feedHeader)
Sets whether to add the feed object as a header
|
void |
setFeedUri(String feedUri)
The URI to the feed to poll.
|
void |
setFilter(boolean filter)
Sets whether to use filtering or not of the entries.
|
void |
setLastUpdate(Date lastUpdate)
Sets the timestamp to be used for filtering entries from the atom feeds.
|
void |
setPassword(String password)
Sets the password to be used for basic authentication when polling from a HTTP feed
|
void |
setSortEntries(boolean sortEntries)
Sets whether to sort entries by published date.
|
void |
setSplitEntries(boolean splitEntries)
Sets whether or not entries should be sent individually or whether the entire
feed should be sent as a single message
|
void |
setThrottleEntries(boolean throttleEntries)
Sets whether all entries identified in a single feed poll should be delivered immediately.
|
void |
setUsername(String username)
Sets the username to be used for basic authentication when polling from a HTTP feed
|
configureConsumer, configureProperties, configureScheduledPollConsumerProperties, doConfigureConsumer, doStart, doStop, getBackoffErrorThreshold, getBackoffIdleThreshold, getBackoffMultiplier, getDelay, getInitialDelay, getPollStrategy, getRepeatCount, getRunLoggingLevel, getScheduledExecutorService, getScheduler, getSchedulerProperties, getTimeUnit, isGreedy, isSendEmptyMessageWhenIdle, isStartScheduler, isUseFixedDelay, setBackoffErrorThreshold, setBackoffIdleThreshold, setBackoffMultiplier, setDelay, setGreedy, setInitialDelay, setPollStrategy, setRepeatCount, setRunLoggingLevel, setScheduledExecutorService, setScheduler, setSchedulerProperties, setSendEmptyMessageWhenIdle, setStartScheduler, setTimeUnit, setUseFixedDelayconfigurePollingConsumer, createAsyncProducer, createExchange, createExchange, createPollingConsumer, doInit, equals, getCamelContext, getComponent, getEndpointUri, getExceptionHandler, getExchangePattern, getId, getPollingConsumerBlockTimeout, getPollingConsumerQueueSize, hashCode, isBasicPropertyBinding, isBridgeErrorHandler, isLazyStartProducer, isPollingConsumerBlockWhenFull, isSingleton, isSynchronous, setBasicPropertyBinding, setBridgeErrorHandler, setCamelContext, setComponent, setEndpointUri, setEndpointUriIfNotSpecified, setExceptionHandler, setExchangePattern, setLazyStartProducer, setPollingConsumerBlockTimeout, setPollingConsumerBlockWhenFull, setPollingConsumerQueueSize, setProperties, setSynchronous, toStringbuild, doBuild, doFail, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspendclone, finalize, getClass, notify, notifyAll, wait, wait, wait@UriPath(description="The URI to the feed to poll.") @Metadata(required=true) protected String feedUri
@UriParam(defaultValue="true",
description="Sets whether or not entries should be sent individually or whether the entire feed should be sent as a single message")
protected boolean splitEntries
@UriParam(description="Sets the timestamp to be used for filtering entries from the atom feeds. This options is only in conjunction with the splitEntries.") protected Date lastUpdate
@UriParam(defaultValue="true",
description="Sets whether to use filtering or not of the entries.")
protected boolean filter
public FeedEndpoint()
public FeedEndpoint(String endpointUri, FeedComponent component, String feedUri)
public org.apache.camel.Consumer createConsumer(org.apache.camel.Processor processor)
throws Exception
createConsumer in interface org.apache.camel.EndpointcreateConsumer in class org.apache.camel.support.DefaultPollingEndpointExceptionprotected abstract FeedPollingConsumer createPollingConsumer(FeedEndpoint feedEndpoint, org.apache.camel.Processor processor) throws Exception
Exceptionprotected abstract FeedPollingConsumer createEntryPollingConsumer(FeedEndpoint feedEndpoint, org.apache.camel.Processor processor, boolean filter, Date lastUpdate, boolean throttleEntries) throws Exception
Exceptionprotected org.apache.camel.Exchange createExchangeWithFeedHeader(Object feed, String header)
public abstract org.apache.camel.Exchange createExchange(Object feed)
feed - the atom feedpublic abstract org.apache.camel.Exchange createExchange(Object feed, Object entry)
feed - the feedentry - the entry as the in bodyprotected String createEndpointUri()
createEndpointUri in class org.apache.camel.support.DefaultEndpointpublic String getEndpointKey()
getEndpointKey in interface org.apache.camel.EndpointgetEndpointKey in class org.apache.camel.support.DefaultEndpointpublic String getFeedUri()
public void setFeedUri(String feedUri)
public boolean isSplitEntries()
public void setSplitEntries(boolean splitEntries)
public Date getLastUpdate()
public void setLastUpdate(Date lastUpdate)
public boolean isFilter()
public void setFilter(boolean filter)
public void setFeedHeader(boolean feedHeader)
public boolean isFeedHeader()
public void setSortEntries(boolean sortEntries)
public boolean isSortEntries()
public boolean isLenientProperties()
isLenientProperties in interface org.apache.camel.EndpointisLenientProperties in class org.apache.camel.support.DefaultEndpointpublic void setThrottleEntries(boolean throttleEntries)
public boolean isThrottleEntries()
public String getUsername()
public void setUsername(String username)
public String getPassword()
public void setPassword(String password)
Apache Camel