HttpServletRequest request,
HttpServletResponse response)
throws Exception {
ActionErrors errors = new ActionErrors();
Channel channel = null;
try {
channel = (Channel)
request.getAttribute(ParseRss.CHANNEL_KEY);
}
catch (Throwable t) {
channel = null;
}
if (null==channel) {
try {
channel = (Channel)
request.getAttribute(mapping.getParameter());
}
catch (Throwable t) {
channel = null;
}
}
if (null==channel) {
errors.add(ActionErrors.GLOBAL_ERROR,
new ActionError(Tokens.PROCESS_MISSING_PARAMETER));
}
if (errors.empty()) {
response.setContentType(Tokens.TEXT_PLAIN);
channel.render(response.getWriter());
}
else {
// This will trigger findFailure() in the BaseAction
saveErrors(request,errors);