/** * Ends the context when exiting the tag. * * @param context The page context to use. */ protected void endContext(PageContext context) { if (attributeContext != null && container != null) { container.endContext(pageContext); } }
/** * Ends the context when exiting the tag. * * @param context The page context to use. */ protected void endContext(PageContext context) { if (attributeContext != null && container != null) { container.endContext(pageContext); } } }
@Override public void endContext(Request request) { container.endContext(request); }
container.endContext(request);
container.endContext(request);
/** * Ends the current attribute context. To be called after * {@link #startAttributeContext()}. * * @return The tool itself. * @since 2.2.0 */ public VelocityStyleTilesTool endAttributeContext() { Request velocityRequest = createVelocityRequest(getServletContext(), null); TilesContainer container = TilesAccess .getCurrentContainer(velocityRequest); container.endContext(velocityRequest); return this; }
/** * * @param actionUrl url should be start with "/" * @param request HttpServletRequest * @param response HttpServletResponse * @throws Exception Exception */ public static void render(String actionUrl, HttpServletRequest request, HttpServletResponse response) throws Exception { TilesContainer container = TilesAccess.getContainer( request.getSession().getServletContext()); AttributeContext attributeContext = container.startContext(request, response); Attribute attr = new Attribute(actionUrl); attributeContext.putAttribute("body", attr); container.render("main.layout", request, response); container.endContext(request, response); }
private void renderTilesView(ExternalContext externalContext, Object[] requestObjects, TilesContainer container, UIViewRoot viewToRender, String viewId, String tilesId) { handleCharacterEncoding(viewId, externalContext, viewToRender); container.startContext(requestObjects); try { container.render(tilesId,requestObjects); } catch (TilesException e) { throw new FacesException(e); } finally { container.endContext(requestObjects); } handleCharacterEncodingPostDispatch(externalContext); }
container.endContext(request);
container.endContext(request);