i’m trying to provide an RSS feed on a site built using JSF 2.0. Before i start to code it my self, i thought i’d ask you guys if there is a standard way to do this? Googling around for a bit didn’t bring up any results, however i also use CakePHP once in a while and there you can just use different views on the same model (xhtml, xml, csv whatever) which makes total sense since this is what using a MVC pattern is all about. Is there any standard layout, component or something like that i can just use? Thank you guys in advance, every hint is highly appreciated!
Share
I’m not hugely familiar with JSF – however I have recently implemented a number of RSS feeds very quickly using Spring 3 (which internally uses the very useful ROME library).
I made particular use of Spring 3’s org.springframework.web.servlet.view.feedAbstractRssFeedView which you can extend to easily allow conversion your domain objects into an RSS view with minimal effort.
The great thing is Spring has other abstract views (such as Atom, or JSON) for easy conversion of your data into other formats for RESTful consumption.
HTH.