Package org.exoplatform.web.url.navigation

Examples of org.exoplatform.web.url.navigation.NavigationResource


                tokenService.deleteToken(token);
            }

            String portalName = prContext.getPortalOwner();
            NodeURL createURL = prContext.createURL(NodeURL.TYPE);
            createURL.setResource(new NavigationResource(SiteType.PORTAL, portalName, null));

            LogoutControl.wantLogout();
            Cookie cookie = new Cookie(LoginServlet.COOKIE_NAME, "");
            cookie.setPath(req.getContextPath());
            cookie.setMaxAge(0);
View Full Code Here


    }

    public class RequestContextURIResolver implements org.gatein.api.common.URIResolver {
        public String resolveURI(SiteId siteId) {
            SiteKey siteKey = Util.from(siteId);
            NavigationResource navResource = new NavigationResource(siteKey, "");
            NodeURL nodeURL = context.createURL(NodeURL.TYPE, navResource);
            String n = nodeURL.toString();
            return n.substring(0, n.length() - 1);
        }
View Full Code Here

    @Override
    public boolean execute(ControllerContext context) throws Exception {
        String defaultPortal = configService.getDefaultPortal();
        PortalURLContext urlContext = new PortalURLContext(context, SiteKey.portal(defaultPortal));
        NodeURL url = urlFactory.newURL(NodeURL.TYPE, urlContext);
        String s = url.setResource(new NavigationResource(SiteType.PORTAL, defaultPortal, "")).toString();
        HttpServletResponse resp = context.getResponse();
        resp.sendRedirect(resp.encodeRedirectURL(s));
        return true;
    }
View Full Code Here

            if (userProfile == null) {
                LogoutControl.wantLogout();
                PortalRequestContext prContext = (PortalRequestContext) context;
                NodeURL createURL = prContext.createURL(NodeURL.TYPE);
                createURL.setResource(new NavigationResource(SiteType.PORTAL, prContext.getPortalOwner(), null));
                prContext.sendRedirect(createURL.toString());
            }
        }

        currentUserProfile.set(userProfile);
View Full Code Here

        this.nodePath_ = requestPath;
        this.requestLocale = requestLocale;

        //
        NodeURL url = createURL(NodeURL.TYPE);
        url.setResource(new NavigationResource(siteKey, ""));
        portalURI = url.toString();

        //
        urlBuilder = new PortalURLBuilder(this, createURL(ComponentURL.TYPE));
    }
View Full Code Here

        //
        PortalURLContext urlContext = new PortalURLContext(context, siteKey);
        NodeURL url = urlFactory.newURL(NodeURL.TYPE, urlContext);

        url.setResource(new NavigationResource(siteKey.getType(), siteKey.getName(), uri));
        url.setMimeType(MimeType.PLAIN);

        Enumeration paraNames = request.getParameterNames();
        while (paraNames.hasMoreElements()) {
            String parameter = paraNames.nextElement().toString();
View Full Code Here

        return urlTemplate.toString();
    }

    public String getBaseURL() throws UnsupportedEncodingException  {
        PortalRequestContext pcontext = Util.getPortalRequestContext();
        NodeURL nodeURL = pcontext.createURL(NodeURL.TYPE, new NavigationResource(pcontext.getSiteKey(), pcontext.getNodePath()));
        return nodeURL.toString();
    }
View Full Code Here

                closePopupListener.execute((Event)event);

                // Redirect to finish login with new user
                SiteKey siteKey = portalRequestContext.getSiteKey();
                NodeURL urlToRedirect = portalRequestContext.createURL(NodeURL.TYPE);
                urlToRedirect.setResource(new NavigationResource(siteKey, portalRequestContext.getNodePath()));

                portalRequestContext.getJavascriptManager().addJavascript("window.location = '" + urlToRedirect.toString() + "';");
            }

        }
View Full Code Here

        this.nodePath_ = requestPath;
        this.requestLocale = requestLocale;

        //
        NodeURL url = createURL(NodeURL.TYPE);
        url.setResource(new NavigationResource(siteKey, ""));
        portalURI = url.toString();

        //
        urlBuilder = new PortalURLBuilder(this, createURL(ComponentURL.TYPE));
    }
View Full Code Here

                tokenService.deleteToken(token);
            }

            String portalName = prContext.getPortalOwner();
            NodeURL createURL = prContext.createURL(NodeURL.TYPE);
            createURL.setResource(new NavigationResource(SiteType.PORTAL, portalName, null));

            LogoutControl.wantLogout();
            Cookie cookie = new Cookie(LoginServlet.COOKIE_NAME, "");
            cookie.setPath(req.getContextPath());
            cookie.setMaxAge(0);
View Full Code Here

TOP

Related Classes of org.exoplatform.web.url.navigation.NavigationResource

Copyright © 2018 www.massapicom. 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.