Class TwitterConsumerServiceImpl
java.lang.Object
io.meeds.twitter.gamification.service.impl.TwitterConsumerServiceImpl
- All Implemented Interfaces:
TwitterConsumerService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncheckTwitterTokenStatus(String bearerToken) Check Twitter token statusgetMentionEvents(TwitterAccount twitterAccount, long lastMentionTweetId, String bearerToken) Retrieve available tweets in which the account identified by its identifier was mentionedretrieveTweetLikers(String tweetLink, String bearerToken) Retrieve the list of tweet likers.retrieveTweetRetweeters(String tweetLink, String bearerToken) Retrieve the list of tweet retweeters.retrieveTwitterAccount(long twitterRemoteId, String bearerToken) Retrieve available Twitter account info.retrieveTwitterAccount(String twitterUsername, String bearerToken) Retrieve available Twitter account info.
-
Constructor Details
-
TwitterConsumerServiceImpl
public TwitterConsumerServiceImpl()
-
-
Method Details
-
retrieveTwitterAccount
public RemoteTwitterAccount retrieveTwitterAccount(String twitterUsername, String bearerToken) throws org.exoplatform.commons.exception.ObjectNotFoundException Description copied from interface:TwitterConsumerServiceRetrieve available Twitter account info.- Specified by:
retrieveTwitterAccountin interfaceTwitterConsumerService- Parameters:
twitterUsername- Twitter account usernamebearerToken- Twitter bearer token- Returns:
RemoteTwitterAccount- Throws:
org.exoplatform.commons.exception.ObjectNotFoundException- when the Twitter account identified by its technical name is not found
-
retrieveTwitterAccount
Description copied from interface:TwitterConsumerServiceRetrieve available Twitter account info.- Specified by:
retrieveTwitterAccountin interfaceTwitterConsumerService- Parameters:
twitterRemoteId- Twitter account remote IdbearerToken- Twitter bearer token- Returns:
RemoteTwitterAccount
-
retrieveTweetLikers
Description copied from interface:TwitterConsumerServiceRetrieve the list of tweet likers.- Specified by:
retrieveTweetLikersin interfaceTwitterConsumerService- Parameters:
tweetLink- Tweet linkbearerToken- Twitter bearer token- Returns:
- the
Listof tweet likers
-
retrieveTweetRetweeters
Description copied from interface:TwitterConsumerServiceRetrieve the list of tweet retweeters.- Specified by:
retrieveTweetRetweetersin interfaceTwitterConsumerService- Parameters:
tweetLink- Tweet linkbearerToken- Twitter bearer token- Returns:
- the
Listof tweet retweeters
-
checkTwitterTokenStatus
Description copied from interface:TwitterConsumerServiceCheck Twitter token status- Specified by:
checkTwitterTokenStatusin interfaceTwitterConsumerService- Parameters:
bearerToken- Twitter bearer token- Returns:
TokenStatus
-
getMentionEvents
public List<TwitterTrigger> getMentionEvents(TwitterAccount twitterAccount, long lastMentionTweetId, String bearerToken) Description copied from interface:TwitterConsumerServiceRetrieve available tweets in which the account identified by its identifier was mentioned- Specified by:
getMentionEventsin interfaceTwitterConsumerService- Parameters:
twitterAccount-TwitterAccountTwitter accountlastMentionTweetId- last mention tweet IdbearerToken- Twitter bearer token
-