It could be nice to have a getDescription method in RssTool that allow language
parameter so the description to be used in rss xml generation can be
localizable.
The method could be something like this:
public String getDescription(PageEntity page, String lang) {
RssatomConfig rssatomConfig = new RssatomConfig(getPlugin());
page.setSkipPostProcessing(true);
String content = StrUtil.extractTextFromHTML(
getBusiness().getPageBusiness().render(page, PAGE_TEMPLATE, lang));
if (StringUtils.isEmpty(content)) {
return "";
}
int end = content.length() > rssatomConfig.getItemSize() ?
rssatomConfig.getItemSize() : content.length();
return content.substring(0, end - 1);
}
Original issue reported on code.google.com by sant...@gmail.com on 28 Jun 2011 at 3:40
Original issue reported on code.google.com by
sant...@gmail.com
on 28 Jun 2011 at 3:40Attachments: