// this process cannot execute with either of these two objects so
// throw an exception if either one or both is missing
if (request == null || response == null) {
Locator locator = context.getCurrentLocator();
XMLProcessingException xmlException =
new XMLProcessingException(
"Null request and response objects in context",
locator);
fatalError(xmlException);
}
// Get valid a RequestDispatcher to dispatch to
RequestDispatcher dispatcher = getRequestDispatcher(request);
try {
dispatcher.include(request, response);
} catch (Exception e) {
Locator locator = getPipelineContext().getCurrentLocator();
XMLProcessingException xmlException =
new XMLProcessingException("Failed to include URI ",
locator, e);
fatalError(xmlException);
}
}
}