Package org.apache.jetspeed.om.page

Examples of org.apache.jetspeed.om.page.ContentPage


        RequestContext a_oRC = new JetspeedRequestContext(request, response,
                config, null);

        Page a_oPage = setupPage();
        ContentPage a_oContentPage = new ContentPageImpl(a_oPage);

        a_oRC.setPage(a_oContentPage);

        return a_oRC;
    }
View Full Code Here


                {
                    PortletWindowSessionNavigationalStates sessionStates = (PortletWindowSessionNavigationalStates)session.getAttribute(NavigationalState.NAVSTATE_SESSION_KEY);
                    if ( sessionStates != null )
                    {
                        sessionStates.removeFromCache(context, clearCacheWindowId, cache);
                        ContentPage page = context.getPage();
                        sessionStates.removeFromCache(context, page.getId(), decorationCache);                       
                    }
                }
            }
        }
        else
View Full Code Here

        return user + mode + context.getPage().getId();       
    }
   
    public void invalidate(RequestContext context)
    {
        ContentPage page = context.getPage();
        ContentCacheKey themeContentCacheKey = createCacheKey(context, page.getId());
        CacheElement themeCacheElem = get(themeContentCacheKey);
       
        if (themeCacheElem != null)
        {
            Theme theme = (Theme) themeCacheElem.getContent();
View Full Code Here

            record.setUserName(userName);
            if (req.getRemoteAddr() != null)
            {
                record.setIpAddress(req.getRemoteAddr());
            }
            ContentPage cp = request.getPage();
            if (cp != null)
            {
                if (cp.getPath() != null)
                {
                    record.setPagePath(cp.getPath());
                }
            }
            record.setStatus(Integer.parseInt(statusCode));
            record.setTimeStamp(timestamp);
            record.setMsElapsedTime(msElapsedTime);
View Full Code Here

            Timestamp timestamp = new Timestamp(System.currentTimeMillis());
            PageLogRecord record = new PageLogRecord();

            record.setUserName(userName);
            record.setIpAddress(req.getRemoteAddr());
            ContentPage cp = request.getPage();
            if (cp != null)
            {
                if (cp.getPath() != null)
                {
                    record.setPagePath(cp.getPath());
                }
            }
            record.setStatus(Integer.parseInt(statusCode));
            record.setTimeStamp(timestamp);
            record.setMsElapsedTime(msElapsedTime);
View Full Code Here

    {
        try
        {
            String pathSave = this.getPath();          
            this.setPath(nonProfiledPath);
            ContentPage realPage = this.getPage();
            this.setPage(null);               
            Map locators = null;
            ProfileLocator locator = profiler.getProfile(this, ProfileLocator.PAGE_LOCATOR);
            if ( locator != null )
            {
                locators = new HashMap();
                locators.put(ProfileLocator.PAGE_LOCATOR, locator);
            }              
            PortalSiteSessionContext sessionContext = (PortalSiteSessionContext)getSessionAttribute(ProfilerValveImpl.PORTAL_SITE_SESSION_CONTEXT_ATTR_KEY);
            String userPrincipal = ((getUserPrincipal() != null) ? getUserPrincipal().getName() : null);
            PortalSiteRequestContext requestContext = sessionContext.newRequestContext(locators, userPrincipal, true, true);
            ContentPage cpage = new ContentPageImpl(requestContext.getManagedPage());
            //System.out.println("page is " + cpage.getPath());
            this.setPage(realPage);           
            this.setPath(pathSave);
            return cpage;
        }
View Full Code Here

     *
     * @return Unique Portlet Entity ID
     */
    public void build( RequestContext context ) throws JetspeedException, IOException
    {
        ContentPage page = context.getPage();
        if (null == page)
        {
            throw new JetspeedException("Failed to find PSML Pin ContentPageAggregator.build");
        }
        ContentFragment root = page.getRootContentFragment();
        if (root == null)
        {
            throw new JetspeedException("No root ContentFragment found in ContentPage");
        }
        // handle maximized state
View Full Code Here

     *
     * @return Unique Portlet Entity ID
     */
    public void build( RequestContext context ) throws JetspeedException, IOException
    {
        ContentPage page = context.getPage();
        if (null == page)
        {
            throw new JetspeedException("Failed to find PSML Pin ContentPageAggregator.build");
        }
        ContentFragment root = page.getRootContentFragment();
        if (root == null)
        {
            throw new JetspeedException("No root ContentFragment found in ContentPage");
        }
        // handle maximized state
View Full Code Here

            if (portletMode != null && !isValidPortletMode(portletMode))
            {
                throw new Exception("portlet mode " + portletMode + " is not supported");
            }

            ContentPage page = requestContext.getPage();           
            ContentFragment fragment = page.getContentFragmentById(portletId);
           
            String oldState = fragment.getState();
            String oldMode = fragment.getMode();
           
            // Now Change the transient navigational state
View Full Code Here

    public void doView( RenderRequest request, RenderResponse response ) throws PortletException, IOException
    {
        RequestContext context = getRequestContext(request);

        ContentPage requestPage = context.getPage();      
        PageEditAccess pageEditAccess = (PageEditAccess)context.getAttribute(PortalReservedParameters.PAGE_EDIT_ACCESS_ATTRIBUTE);
        if ( requestPage == null || pageEditAccess == null )
        {
            // Targetting this portlet REQUIRES that the ProfilerValve has been invoked!
            throw new PortletException("Current request page or PageEditAccess not available.");
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.om.page.ContentPage

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.