Package org.apache.jetspeed.om.registry

Examples of org.apache.jetspeed.om.registry.PortletEntry.addParameter()


                entry.setTitle("The Kahuna Portlet");
                entry.setType(PortletEntry.TYPE_ABSTRACT);               
                entry.setURL("http://bigkahuna.org");
                   
                // parameters
                entry.addParameter("simple", "simple-value");
               
                CachedParameter param = new BaseCachedParameter();
                param.setDescription("pdescription");
                param.setHidden(false);
                meta = new BaseMetaInfo();
View Full Code Here


                ref2.setParent("admin-only");               
                param.setSecurityRef(ref2);
                param.setTitle("Coconut");
                param.setType("hmm");
                param.setValue("hawaii");
                entry.addParameter(param);
                param.setCachedOnName(true);
                param.setCachedOnValue(false);

               
                param = new BaseCachedParameter();
View Full Code Here

                ref3.setParent("second admin-only");               
                param.setSecurityRef(ref3);
                param.setTitle("second Coconut");
                param.setType("second hmm");
                param.setValue("second hawaii");
                entry.addParameter(param);
                param.setCachedOnName(false);
                param.setCachedOnValue(true);
               
                // media types
                entry.addMediaType("xml");
View Full Code Here

            assertNotNull(pe);
            assertPortlet(pe);
           
            pe.addCategory("cat4");
            pe.setDescription("new description");
            pe.addParameter("last", "lastvalue");
            pe.addMediaType("vml");
           
            Registry.saveEntry(Registry.PORTLET, (RegistryEntry)pe);
           
            PortletEntry pe2 = (PortletEntry)Registry.getEntry(Registry.PORTLET, "BigKahuna");
View Full Code Here

            {
                SecurityReference ref2 = new BaseSecurityReference();
                ref2.setParent(pp.getSecurityRef());
                cp.setSecurityRef(ref2);
            }           
            pe.addParameter(cp);
        }
       
        // media types
        Iterator mtypes = pde.getPortletMediatypes().iterator();
        while (mtypes.hasNext())
View Full Code Here

            {
                param.setValue(value);
            }
            else
            {
                pEntry.addParameter(name, value);
            }
        }
    }
}
View Full Code Here

        Parameter adminParam = new BaseParameter();
        assertNotNull( "Have adminParameter", adminParam);
        adminParam.setName("AdminParam");
        adminParam.setValue("adminValue");
        adminParam.setSecurity(adminSecurity);
        userPortletEntry.addParameter(adminParam);

        Parameter userParam = new BaseParameter();
        assertNotNull( "Have userParameter", userParam);
        userParam.setName("UserParam");
        userParam.setValue("userValue");
View Full Code Here

        Parameter userParam = new BaseParameter();
        assertNotNull( "Have userParameter", userParam);
        userParam.setName("UserParam");
        userParam.setValue("userValue");
        userParam.setSecurity(userSecurity);
        userPortletEntry.addParameter(userParam);
        assertEquals( "Admin user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( adminUser, new PortalResource( userPortletEntry, adminParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Turbine user customize access to admin parameter", false, JetspeedPortalAccessController.checkPermission( turbineUser, new PortalResource( userPortletEntry, adminParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Admin user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( adminUser, new PortalResource( userPortletEntry, userParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Turbine user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( turbineUser, new PortalResource( userPortletEntry, userParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
       
View Full Code Here

        Parameter adminParam = new BaseParameter();
        assertNotNull( "Have adminParameter", adminParam);
        adminParam.setName("AdminParam");
        adminParam.setValue("adminValue");
        adminParam.setSecurity(adminSecurity);
        userPortletEntry.addParameter(adminParam);

        Parameter userParam = new BaseParameter();
        assertNotNull( "Have userParameter", userParam);
        userParam.setName("UserParam");
        userParam.setValue("userValue");
View Full Code Here

        Parameter userParam = new BaseParameter();
        assertNotNull( "Have userParameter", userParam);
        userParam.setName("UserParam");
        userParam.setValue("userValue");
        userParam.setSecurity(userSecurity);
        userPortletEntry.addParameter(userParam);
        assertEquals( "Admin user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( adminUser, new PortalResource( userPortletEntry, adminParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Turbine user customize access to admin parameter", false, JetspeedPortalAccessController.checkPermission( turbineUser, new PortalResource( userPortletEntry, adminParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Admin user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( adminUser, new PortalResource( userPortletEntry, userParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
        assertEquals( "Turbine user customize access to admin parameter", true, JetspeedPortalAccessController.checkPermission( turbineUser, new PortalResource( userPortletEntry, userParam), JetspeedSecurity.PERMISSION_CUSTOMIZE));
       
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.