Class TwitterConfiguration


  • @UriParams
    public class TwitterConfiguration
    extends Object
    • Constructor Detail

      • TwitterConfiguration

        public TwitterConfiguration()
    • Method Detail

      • checkComplete

        public void checkComplete()
        Ensures required fields are available.
      • getConfiguration

        public twitter4j.conf.Configuration getConfiguration()
        Builds a Twitter4J Configuration using the OAuth params.
        Returns:
        Configuration
      • getTwitter

        public twitter4j.Twitter getTwitter()
      • setTwitter

        public void setTwitter​(twitter4j.Twitter twitter)
      • getConsumerKey

        public String getConsumerKey()
      • setConsumerKey

        public void setConsumerKey​(String consumerKey)
        The consumer key. Can also be configured on the TwitterComponent level instead.
      • getConsumerSecret

        public String getConsumerSecret()
      • setConsumerSecret

        public void setConsumerSecret​(String consumerSecret)
        The consumer secret. Can also be configured on the TwitterComponent level instead.
      • getAccessToken

        public String getAccessToken()
        The access token. Can also be configured on the TwitterComponent level instead.
      • setAccessToken

        public void setAccessToken​(String accessToken)
      • getAccessTokenSecret

        public String getAccessTokenSecret()
        The access secret. Can also be configured on the TwitterComponent level instead.
      • setAccessTokenSecret

        public void setAccessTokenSecret​(String accessTokenSecret)
      • setType

        public void setType​(EndpointType type)
        Endpoint type to use.
      • getLocations

        public String getLocations()
      • setLocations

        public void setLocations​(String locations)
        Bounding boxes, created by pairs of lat/lons. Can be used for filter. A pair is defined as lat,lon. And multiple paris can be separated by semi colon.
      • getUserIds

        public String getUserIds()
      • setUserIds

        public void setUserIds​(String userIds)
        To filter by user ids for filter. Multiple values can be separated by comma.
      • isFilterOld

        public boolean isFilterOld()
      • setFilterOld

        public void setFilterOld​(boolean filterOld)
        Filter out old tweets, that has previously been polled. This state is stored in memory only, and based on last tweet id.
      • getSinceId

        public long getSinceId()
      • setSinceId

        public void setSinceId​(long sinceId)
        The last tweet id which will be used for pulling the tweets. It is useful when the camel route is restarted after a long running.
      • getLang

        public String getLang()
      • setLang

        public void setLang​(String lang)
        The lang string ISO_639-1 which will be used for searching
      • getCount

        public Integer getCount()
      • setCount

        public void setCount​(Integer count)
        Limiting number of results per page.
      • getNumberOfPages

        public Integer getNumberOfPages()
      • setNumberOfPages

        public void setNumberOfPages​(Integer numberOfPages)
        The number of pages result which you want camel-twitter to consume.
      • isSortById

        public boolean isSortById()
      • setSortById

        public void setSortById​(boolean sortById)
        Sorts by id, so the oldest are first, and newest last.
      • setHttpProxyHost

        public void setHttpProxyHost​(String httpProxyHost)
        The http proxy host which can be used for the camel-twitter. Can also be configured on the TwitterComponent level instead.
      • getHttpProxyHost

        public String getHttpProxyHost()
      • setHttpProxyUser

        public void setHttpProxyUser​(String httpProxyUser)
        The http proxy user which can be used for the camel-twitter. Can also be configured on the TwitterComponent level instead.
      • getHttpProxyUser

        public String getHttpProxyUser()
      • setHttpProxyPassword

        public void setHttpProxyPassword​(String httpProxyPassword)
        The http proxy password which can be used for the camel-twitter. Can also be configured on the TwitterComponent level instead.
      • getHttpProxyPassword

        public String getHttpProxyPassword()
      • setHttpProxyPort

        public void setHttpProxyPort​(Integer httpProxyPort)
        The http proxy port which can be used for the camel-twitter. Can also be configured on the TwitterComponent level instead.
      • getHttpProxyPort

        public Integer getHttpProxyPort()
      • getLongitude

        public Double getLongitude()
      • setLongitude

        public void setLongitude​(Double longitude)
        Used by the geography search to search by longitude.

        You need to configure all the following options: longitude, latitude, radius, and distanceMetric.

      • getLatitude

        public Double getLatitude()
      • setLatitude

        public void setLatitude​(Double latitude)
        Used by the geography search to search by latitude.

        You need to configure all the following options: longitude, latitude, radius, and distanceMetric.

      • getRadius

        public Double getRadius()
      • setRadius

        public void setRadius​(Double radius)
        Used by the geography search to search by radius.

        You need to configure all the following options: longitude, latitude, radius, and distanceMetric.

      • getDistanceMetric

        public String getDistanceMetric()
      • setDistanceMetric

        public void setDistanceMetric​(String distanceMetric)
        Used by the geography search, to search by radius using the configured metrics.

        The unit can either be mi for miles, or km for kilometers.

        You need to configure all the following options: longitude, latitude, radius, and distanceMetric.

      • setExtendedMode

        public void setExtendedMode​(Boolean extendedMode)
        Used for enabling full text from twitter (eg receive tweets that contains more than 140 characters).
      • isExtendedMode

        public boolean isExtendedMode()