This content has been marked as final.
Show 3 replies
-
1. Re: No such method --> org.jboss.portal.portlet.impl.jsr168.
wesleyhales Aug 23, 2009 10:10 AM (in response to jberdat2)Try this when you generate the chart:
Object responseObject = FacesContext.getCurrentInstance().getExternalContext().getResponse(); if (responseObject instanceof RenderResponse) { BufferedRenderResponseWrapper brrw = (BufferedRenderResponseWrapper)responseObject; RenderResponse response = brrw.getResponse(); response.getPortletOutputStream().write(getFiles().get((Integer)object).getData()); }else{ //servlet response stream.write(getFiles().get((Integer)object).getData()); }
-
2. Re: No such method --> org.jboss.portal.portlet.impl.jsr168.
jberdat2 Aug 23, 2009 10:43 AM (in response to jberdat2)The problem is that the request is not even reaching my method for generating the chart. It crashes when trying to get the outputStream (maybe a question for rich faces guys). The ajax4jsf tag need to have a method with the following parameters: genChart(OutputStream out, Object value)
So I think I've misconfigured something, because org.ajax4jsf.resource.FacesResourceContext.getOutputStream lookup the stream on ResourceResponseImpl.getOutputStream instead of ResourceResponseImpl.getPortletOutputStream. -
3. Re: No such method --> org.jboss.portal.portlet.impl.jsr168.
jberdat2 Aug 23, 2009 11:46 AM (in response to jberdat2)I've done the following which solved my problem. I overwrite the class:
org.jboss.portal.portlet.impl.jsr168.api.MimeResponseImpl
and added the following:
public OutputStream getOutputStream() throws IOException {
return this.getPortletOutputStream();
}