Another note to point out new features in abdera2...

As part of the Activity Streams implementation, there is a new
mechanism for converting an Atom Feed to an Activity Stream... it
should work with any Atom Feed, including those that using the
Activity Streams Atom spec (http://activitystrea.ms/specs/atom/1.0)


     Abdera abdera = Abdera.getInstance();
     URL url = new URL("http://intertwingly.net/blog/index.atom";);
     Parser parser = abdera.getParser();
     ParserOptions options = parser.getDefaultParserOptions();
     options.setCharset("UTF-8");
     Document<Feed> doc =
abdera.getParser().parse(url.openStream(),url.toString(),options);
     Feed feed = doc.getRoot();

     FeedToActivityConverter c = new FeedToActivityConverter() {};

     IO io = IO.get();

     CollectionWriter cw = io.getCollectionWriter(System.out, "UTF-8");

     c.convert(feed, cw);


You can subclass the FeedToActivityConverter class to customize the
conversion process.

Reply via email to