1 16 17 package org.apache.jetspeed.services; 18 19 import org.apache.jetspeed.om.security.JetspeedUser; 21 import org.apache.jetspeed.om.profile.Entry; 22 import org.apache.jetspeed.portal.Portlet; 23 import org.apache.jetspeed.services.security.PortalAccessController; 24 import org.apache.jetspeed.services.security.PortalResource; 25 26 import org.apache.turbine.services.TurbineServices; 28 29 35 public abstract class JetspeedPortalAccessController 36 { 37 38 39 public JetspeedPortalAccessController() 40 { 41 } 42 43 49 protected static PortalAccessController getService() 50 { 51 return (PortalAccessController)TurbineServices 52 .getInstance().getService(PortalAccessController.SERVICE_NAME); 53 } 54 55 public static boolean checkPermission(JetspeedUser user, Entry entry, String action) 56 { 57 return getService().checkPermission(user, entry, action); 58 } 59 60 public static boolean checkPermission(JetspeedUser user, Portlet portlet, String action) 61 { 62 return getService().checkPermission(user, portlet, action); 63 } 64 65 public static boolean checkPermission(JetspeedUser user, PortalResource resource, String action) 66 { 67 return getService().checkPermission(user, resource, action); 68 } 69 70 } 71 | Popular Tags |