org.springframework.integration.adapter
Class PollingSourceAdapter<T>
java.lang.Object
org.springframework.integration.adapter.AbstractSourceAdapter<T>
org.springframework.integration.adapter.PollingSourceAdapter<T>
- All Implemented Interfaces:
- org.springframework.beans.factory.InitializingBean, org.springframework.context.Lifecycle, SourceAdapter, MessagingTaskSchedulerAware
- Direct Known Subclasses:
- ByteStreamSourceAdapter, CharacterStreamSourceAdapter, FileSourceAdapter, JmsPollingSourceAdapter
public class PollingSourceAdapter<T>
- extends AbstractSourceAdapter<T>
- implements MessagingTaskSchedulerAware, org.springframework.context.Lifecycle
A channel adapter that retrieves objects from a PollableSource,
delegates to a MessageMapper to create messages from those objects,
and then sends the resulting messages to the provided MessageChannel.
- Author:
- Mark Fisher
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PollingSourceAdapter
public PollingSourceAdapter(PollableSource<T> source)
setInitialDelay
public void setInitialDelay(long intialDelay)
setPeriod
public void setPeriod(long period)
setMaxMessagesPerTask
public void setMaxMessagesPerTask(int maxMessagesPerTask)
setMessagingTaskScheduler
public void setMessagingTaskScheduler(MessagingTaskScheduler scheduler)
- Specified by:
setMessagingTaskScheduler in interface MessagingTaskSchedulerAware
getSource
protected PollableSource<T> getSource()
isRunning
public boolean isRunning()
- Specified by:
isRunning in interface org.springframework.context.Lifecycle
start
public void start()
- Specified by:
start in interface org.springframework.context.Lifecycle
stop
public void stop()
- Specified by:
stop in interface org.springframework.context.Lifecycle
processMessages
public int processMessages()