Package twitter4j

Examples of twitter4j.PagableResponseList


    private static <T extends TwitterResponse> List<T> asList(ListGenerator<T> g) throws TwitterClientException {
        List<T> l = new LinkedList<T>();

        long cursor = -1;
        PagableResponseList p;
        do {
            try {
                p = g.getList(cursor);
            } catch (TwitterException e) {
                throw new TwitterClientException(e);
            }
            l.addAll(p);
            cursor = p.getNextCursor();
        } while (p.hasNext());

        return l;
    }
View Full Code Here

TOP

Related Classes of twitter4j.PagableResponseList

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.