为什么我从我的代码中收到以下错误?
错误 500:请求处理失败;嵌套异常是 java.lang.IllegalArgumentException: Request must not be null
代码片段
protected void buildPdfDocument(Map modelo, Document document, PdfWriter pdfWriter, HttpServletRequest request, HttpServletResponse response) throws IOException
{
// The problem is here to pass HttpServletRequest to ActionRequest or PortletRequest
ActionRequest aRequest = (ActionRequest) request.getAttribute("javax.portlet.request");
// I need to validate user's session
Cliente cliente = (Cliente) PortletUtils.getSessionAttribute(aRequest, AtokConstante.CLIENTE_SESION,PortletSession.APPLICATION_SCOPE);
}