public class DirectMessageReceivingMessageSource
extends org.springframework.integration.context.IntegrationObjectSupport
| Constructor and Description |
|---|
DirectMessageReceivingMessageSource(org.springframework.social.twitter.api.Twitter twitter,
java.lang.String metadataKey) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getComponentType() |
long |
getLastProcessedId() |
protected org.springframework.social.twitter.api.Twitter |
getTwitter() |
protected void |
onInit() |
protected java.util.List<org.springframework.social.twitter.api.DirectMessage> |
pollForTweets(long sinceId)
Subclasses must implement this to return tweets.
|
org.springframework.integration.Message<?> |
receive() |
void |
setMetadataStore(org.springframework.integration.metadata.MetadataStore metadataStore) |
void |
setPrefetchThreshold(int prefetchThreshold) |
afterPropertiesSet, getApplicationContextId, getBeanFactory, getComponentName, getConversionService, getIntegrationProperties, getIntegrationProperty, getTaskScheduler, setApplicationContext, setBeanFactory, setBeanName, setComponentName, setConversionService, setTaskScheduler, toStringpublic DirectMessageReceivingMessageSource(org.springframework.social.twitter.api.Twitter twitter,
java.lang.String metadataKey)
public java.lang.String getComponentType()
getComponentType in interface org.springframework.integration.support.context.NamedComponentgetComponentType in class org.springframework.integration.context.IntegrationObjectSupportprotected java.util.List<org.springframework.social.twitter.api.DirectMessage> pollForTweets(long sinceId)
public void setMetadataStore(org.springframework.integration.metadata.MetadataStore metadataStore)
public void setPrefetchThreshold(int prefetchThreshold)
protected org.springframework.social.twitter.api.Twitter getTwitter()
protected void onInit()
throws java.lang.Exception
onInit in class org.springframework.integration.context.IntegrationObjectSupportjava.lang.Exceptionpublic org.springframework.integration.Message<?> receive()
receive in interface org.springframework.integration.core.MessageSource@ManagedAttribute public long getLastProcessedId()
-1 if lastProcessedId is not set, yet.