"Please contact your system administrator for assistance.");
return;
}
try {
ContentNode node = translatePath(wcr, request.getPathInfo());
if (node == null) {
error(request, response, "Path " + request.getPathInfo() +
" not found.");
return;
}
String action = request.getParameter("action");
if (action == null && ServletFileUpload.isMultipartContent(request)) {
action = "upload";
}
if (action != null) {
node = handleAction(request, response, node, action);
if (node == null) {
// indicates that the action has handled forwarding on
// its own, for example to the error page
return;
}
}
DirectoryEntry current = new DirectoryEntry(node);
request.setAttribute("current", current);
if (node instanceof ContentCollection) {
handleCollection(request, response, (ContentCollection) node);
} else if (node instanceof ContentResource) {
handleResource(request, response, (ContentResource) node);
} else {
error(request, response, "Unknown node type " + node.getClass());
}
} catch (ContentRepositoryException cre) {
throw new ServletException(cre);
}
}