Examples of UrlExtractor


Examples of de.jetwick.tw.UrlExtractor

    JTweet createTweet(long id, String url) {
        return createTweetWithUrlEntries(id, url, 0, url).setCreatedAt(new Date());
    }

    JTweet createTweetWithUrlEntries(long id, String url, int rt, final String origUrl) {
        UrlExtractor extractor = new UrlExtractor() {

            @Override
            public JResult getInfo(String url, int timeout) throws Exception {
                return UrlEntry.createSimpleResult(origUrl);
            }
        };
        JTweet tw = new JTweet(id, "text is not important " + url, new JUser("timetabling")).setRetweetCount(rt);
        extractor.setTweet(tw);
        tw.setUrlEntries(extractor.run().getUrlEntries());       
        return tw;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.