Package org.apache.jetspeed.om.page

Examples of org.apache.jetspeed.om.page.ContentFragmentImpl$ContentFragmentList


                if (null == actionWindow.getPortletEntity())
                {
                    try
                    {
                        Fragment fragment = request.getPage().getFragmentById(actionWindow.getId().toString());
                        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
                        actionWindow = this.windowAccessor.getPortletWindow(contentFragment);
                    }
                    catch (Exception e)
                    {
                        log.error("Failed to refresh action window.", e);
View Full Code Here


    }

    public void testWindowAccess() throws Exception
    {
        List windows = new ArrayList();
        ContentFragment f1 = new ContentFragmentImpl((Fragment) fragMock.proxy(), new HashMap());
        MutablePortletEntity entity = (MutablePortletEntity) entityMock.proxy();
        CompositeWindowList windowList = (CompositeWindowList) windowListMock.proxy();
        entityAccessMock.expects(new InvokeAtLeastOnceMatcher()).method("getPortletEntityForFragment")
                .withAnyArguments().will(new ReturnStub(entity));
        fragMock.expects(new InvokeAtLeastOnceMatcher()).method("getId").withNoArguments()
View Full Code Here

        {       
            fragment = new PortletAggregatorFragmentImpl(entity);       
            fragment.setType(Fragment.PORTLET);
            fragment.setName(name);
        }
        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
        renderer.renderNow(contentFragment, context);
        context.getResponse().getWriter().write(contentFragment.getRenderedContent());
    }
View Full Code Here

        PortletAggregatorFragmentImpl fragment = new PortletAggregatorFragmentImpl(
                entityId);
        fragment.setType(Fragment.PORTLET);
        fragment.setName(portletId);
        ContentFragment contentFragment = new ContentFragmentImpl(fragment,
                new HashMap());
        //renderer.renderNow(contentFragment, context);
        renderer.render(contentFragment, context);
        return contentFragment.getRenderedContent();
    }
View Full Code Here

                // Under some clustered environments, a cached portlet window could have null entity.
                if (null == resourceWindow.getPortletEntity())
                {
                    try
                    {
                        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
                        resourceWindow = this.windowAccessor.getPortletWindow(contentFragment);
                    }
                    catch (Exception e)
                    {
                        log.error("Failed to refresh resource window.", e);
View Full Code Here

                    {
                        Fragment fragment = request.getPage().getFragmentById(actionWindow.getId().toString());
                       
                        if (fragment != null)
                        {
                            ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
                            actionWindow = this.windowAccessor.getPortletWindow(contentFragment);
                        }
                    }
                    catch (Exception e)
                    {
View Full Code Here

        PortletAggregatorFragmentImpl fragment = new PortletAggregatorFragmentImpl(
                entityId);
        fragment.setType(Fragment.PORTLET);
        fragment.setName(portletId);
        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap(), true);
        renderer.renderNow(contentFragment, context);
        return contentFragment.getRenderedContent();
    }
View Full Code Here

            }
            fragment = new PortletAggregatorFragmentImpl(entity);       
            fragment.setType(Fragment.PORTLET);
            fragment.setName(name);
        }
        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
        renderer.renderNow(contentFragment, context);
        context.getResponse().getWriter().write(contentFragment.getRenderedContent());
    }
View Full Code Here

    }

    public void testWindowAccess() throws Exception
    {
        List windows = new ArrayList();
        ContentFragment f1 = new ContentFragmentImpl((Fragment) fragMock.proxy(), new HashMap());
        MutablePortletEntity entity = (MutablePortletEntity) entityMock.proxy();
        CompositeWindowList windowList = (CompositeWindowList) windowListMock.proxy();
        entityAccessMock.expects(new InvokeAtLeastOnceMatcher()).method("getPortletEntityForFragment")
                .withAnyArguments().will(new ReturnStub(entity));
        fragMock.expects(new InvokeAtLeastOnceMatcher()).method("getId").withNoArguments()
View Full Code Here

        {
            // decorator = context.getPage().getDefaultDecorator(fragment.getType());
            log.debug("No sepecific decorator portlet so using page default: "+decorator);
        }
        ContentDispatcher dispatcher = renderer.getDispatcher(context, false);
        ContentFragment contentFragment = new ContentFragmentImpl(fragment, new HashMap());
        renderer.renderNow(contentFragment, context);
//        dispatcher.include(fragment);
        context.getResponse().getWriter().write(contentFragment.getRenderedContent());
    }
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.om.page.ContentFragmentImpl$ContentFragmentList

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.