Package com.streamreduce.util

Examples of com.streamreduce.util.TwitterClient


                    connection.getId(), connection.getUrl(), e.getMessage()));
        }
    }

    private void pullTwitterActivity(Connection connection) {
        TwitterClient client = (TwitterClient)getClient(connection);

        try {
            JSONObject profile = client.getLoggedInProfile();

            if (profile == null) {
                logger.error("User's profile for Twitter connection %s came back null.", connection.getId());
                return;
            }
View Full Code Here


     * {@inheritDoc}
     */
    @Override
    public String getIdentityFromProvider(Connection c) {
        try {
            TwitterClient twitterClient = getClient(c);
            JSONObject jsonObject = twitterClient.getLoggedInProfile();
            return jsonObject.getString("screen_name");
        } catch (Exception e) {
            throw new RuntimeException(e);
        }
    }
View Full Code Here

    /**
     {@inheritDoc}
     */
    @Override
    public TwitterClient getClient(Connection connection) {
        return new TwitterClient(connection,getOAuthService());
    }
View Full Code Here

TOP

Related Classes of com.streamreduce.util.TwitterClient

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.