pubsubhubbub link with Project Rome
Posted
by itsadok
on Stack Overflow
See other posts from Stack Overflow
or by itsadok
Published on 2010-05-06T07:25:06Z
Indexed on
2010/05/06
13:28 UTC
Read the original article
Hit count: 470
I want to use Project Rome to create an RSS feed, using the code from the tutorial as base. I would like to add a pubsubhubbub discovery link, but there doesn't seem to be a general way to do so.
I can use a Link
object if I create an atom feed (which I don't want to limit myself to), or I can just add foreign markup, like this:
// import org.jdom.Element
Element element = new Element("link");
element.setAttribute("rel", "hub");
element.setAttribute("href", "https://myhub.example.com/endpoint");
feed.setForeignMarkup(Arrays.asList(element));
But it feels ugly.
Is this really the best way to do this?
© Stack Overflow or respective owner