Package javax.portlet

Examples of javax.portlet.PortletSession.removeAttribute()


    protected void doView(RenderRequest request, RenderResponse response)
            throws PortletException, IOException {
        PortletSession portletSession = request.getPortletSession();
        String definition = (String) portletSession.getAttribute("definition");
        if (definition != null) {
            portletSession.removeAttribute("definition");
            TilesContainer container = PortletUtil.getCurrentContainer(request,
                    getPortletContext());
            if (container.isValidDefinition(definition, request, response,
                    getPortletContext())) {
                container.render(definition, request, response,
View Full Code Here


            catch (Exception e)
            {
                throw new PortletException("Failed to update portlet", e);
            }
            PortletSession session = request.getPortletSession();
            session.removeAttribute(PORTLETS);
            session.removeAttribute(CATEGORIES);
            actionResponse.setPortletMode(PortletMode.VIEW);
            actionResponse.setRenderParameter(JSPAGE, page);
        }
        else
View Full Code Here

            {
                throw new PortletException("Failed to update portlet", e);
            }
            PortletSession session = request.getPortletSession();
            session.removeAttribute(PORTLETS);
            session.removeAttribute(CATEGORIES);
            actionResponse.setPortletMode(PortletMode.VIEW);
            actionResponse.setRenderParameter(JSPAGE, page);
        }
        else
        {           
View Full Code Here

        {           
          String reset = request.getParameter("reset");       
            if (reset != null && reset.equals("true"))
            {
                PortletSession session = request.getPortletSession();
                session.removeAttribute(PORTLETS);
                session.removeAttribute(CATEGORIES);
            }
            String category = request.getParameter(CATEGORY);
            if (category != null)
                actionResponse.setRenderParameter(CATEGORY, category);
View Full Code Here

          String reset = request.getParameter("reset");       
            if (reset != null && reset.equals("true"))
            {
                PortletSession session = request.getPortletSession();
                session.removeAttribute(PORTLETS);
                session.removeAttribute(CATEGORIES);
            }
            String category = request.getParameter(CATEGORY);
            if (category != null)
                actionResponse.setRenderParameter(CATEGORY, category);
            String pageNumber = request.getParameter(PAGENUMNER);
View Full Code Here

    protected void removeAttribute(String key)
    {
        PortletSession portletSession = getSession();
        if (portletSession != null)
        {
            portletSession.removeAttribute(key, PortletSession.PORTLET_SCOPE);
        }
    }

    protected Enumeration getAttributeNames()
    {
View Full Code Here

    {
       PortletSession session = request.getPortletSession();
       session.setAttribute(REDEPLOY_FLAG, "portlet was not redeployed");
       FacesContext context = FacesContext.getCurrentInstance();
       if (context != null) context.release();
       session.removeAttribute(this.CURRENT_FACES_CONTEXT);
    }

    /**
     * This method follows JSF Spec section 2.1.1.  It renders the default view from a non-faces
     * request.
 
View Full Code Here

    protected void removeAttribute(String key)
    {
        PortletSession portletSession = getSession();
        if (portletSession != null)
        {
            portletSession.removeAttribute(key, PortletSession.PORTLET_SCOPE);
        }
    }

    protected Enumeration getAttributeNames()
    {
View Full Code Here

            catch (Exception e)
            {
                throw new PortletException("Failed to update portlet", e);
            }
            PortletSession session = request.getPortletSession();
            session.removeAttribute(PORTLETS);
            session.removeAttribute(CATEGORIES);
            actionResponse.setPortletMode(PortletMode.VIEW);
            actionResponse.setRenderParameter(JSPAGE, page);
        }
        else
View Full Code Here

            {
                throw new PortletException("Failed to update portlet", e);
            }
            PortletSession session = request.getPortletSession();
            session.removeAttribute(PORTLETS);
            session.removeAttribute(CATEGORIES);
            actionResponse.setPortletMode(PortletMode.VIEW);
            actionResponse.setRenderParameter(JSPAGE, page);
        }
        else
        {           
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.