1 16 17 package org.apache.jetspeed.services.persistence; 18 19 import java.util.List ; 20 21 import org.apache.jetspeed.om.profile.Profile; 22 import org.apache.jetspeed.portal.*; 23 import org.apache.jetspeed.portal.Portlet; 24 import org.apache.jetspeed.portal.PortletException; 25 import org.apache.turbine.services.TurbineServices; 26 import org.apache.turbine.util.RunData; 27 28 35 public abstract class PersistenceManager 36 { 37 43 public static List getInstances(Profile profile) throws PortletException 44 { 45 return getService().getInstances(profile); 46 } 47 48 54 public static List getInstances(RunData data) throws PortletException 55 { 56 return getService().getInstances(data); 57 } 58 59 66 public static PortletInstance getInstance(Portlet portlet, Profile profile) 67 { 68 return getService().getInstance(portlet, profile); 69 } 70 71 78 public static PortletInstance getInstance(Portlet portlet, RunData data) 79 { 80 return getService().getInstance(portlet, data); 81 } 82 83 91 public static void store(PortletInstance pPortlet) throws PortalPersistenceException 92 { 93 getService().store(pPortlet); 94 } 95 96 97 protected static PortalPersistenceService getService() 98 { 99 return (PortalPersistenceService) TurbineServices.getInstance().getService( 100 "PortalPersistenceService"); 101 } 102 103 } | Popular Tags |