protected SyndicationFeed getResults(Context context, String format, String query, int totalResults, int start,
int pageSize,
DSpaceObject scope, List<DSpaceObject> results, Map<String, String> labels) {
if ("rss".equals(format)) {
format = "rss_2.0";
} else if ("atom".equals(format)) {
format = "atom_1.0";
}
SyndicationFeed feed = new SyndicationFeed(labels.get(SyndicationFeed.MSG_UITYPE));
feed.populate(null, context, scope, results, labels);
feed.setType(format);
feed.addModule(openSearchMarkup(query, totalResults, start, pageSize));
return feed;
}