Hi guys,

Basically to get StreamingAddResouce working on all ExternalContext implementations we need change:

WritablePositionedInfo.writePositionedInfo(HttpServletResponse response, ResponseWriter writer)
StreamablePositionedInfo.writePositionedInfo(HttpServletResponse response, PrintWriter writer)

to

WritablePositionedInfo.writePositionedInfo(ExternalContext context, ResponseWriter writer)
StreamablePositionedInfo.writePositionedInfo(ExternalContext context, PrintWriter writer)

the first scenario only works on ServletContext, but if we want make some components avaliable on others contexts we need give External context as parameter since this will contain an Context Response implementation, this will make StreamingAddResouce more generic instead of something Servlet centric.

In the most circunstances the only thing called from context response is encodeURL method, but the correct is FacesContext.getCurrentInstance().getExternalContext().encodeResourceURL(String url);

For PortletContexts this will only works on Portlet portals that uses ServletFilters (Jetspeed, Liferay).

Any comments?

--
Yours truly (Atenciosamente),

Rogério

Reply via email to