com.liferay.portal.service
Class RoleServiceUtil
java.lang.Object
com.liferay.portal.service.RoleServiceUtil
- public class RoleServiceUtil
- extends java.lang.Object
View Source
ServiceBuilder generated this class. Modifications in this class will be overwritten
the next time is generated.
This class provides static methods for the com.liferay.portal.service.RoleService
bean. The static methods of this class calls the same methods of the bean instance.
It's convenient to be able to just write one line to call a method on a bean
instead of writing a lookup call and a method call.
com.liferay.portal.service.RoleServiceFactory
is responsible for
the lookup of the bean.
- Author:
- Brian Wing Shun Chan
- See Also:
RoleService
,
RoleServiceFactory
Method Summary |
static Role |
addRole(java.lang.String name,
int type)
|
static void |
deleteRole(long roleId)
|
static Role |
getGroupRole(long companyId,
long groupId)
|
static java.util.List |
getGroupRoles(long groupId)
|
static Role |
getRole(long roleId)
|
static Role |
getRole(long companyId,
java.lang.String name)
|
static java.util.List |
getUserGroupRoles(long userId,
long groupId)
|
static java.util.List |
getUserRelatedRoles(long userId,
java.util.List groups)
|
static java.util.List |
getUserRoles(long userId)
|
static boolean |
hasUserRole(long userId,
long companyId,
java.lang.String name,
boolean inherited)
|
static boolean |
hasUserRoles(long userId,
long companyId,
java.lang.String[] names,
boolean inherited)
|
static Role |
updateRole(long roleId,
java.lang.String name)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RoleServiceUtil
public RoleServiceUtil()
addRole
public static Role addRole(java.lang.String name,
int type)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
deleteRole
public static void deleteRole(long roleId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getGroupRole
public static Role getGroupRole(long companyId,
long groupId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getGroupRoles
public static java.util.List getGroupRoles(long groupId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getRole
public static Role getRole(long roleId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getRole
public static Role getRole(long companyId,
java.lang.String name)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getUserGroupRoles
public static java.util.List getUserGroupRoles(long userId,
long groupId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getUserRelatedRoles
public static java.util.List getUserRelatedRoles(long userId,
java.util.List groups)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
getUserRoles
public static java.util.List getUserRoles(long userId)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
hasUserRole
public static boolean hasUserRole(long userId,
long companyId,
java.lang.String name,
boolean inherited)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
hasUserRoles
public static boolean hasUserRoles(long userId,
long companyId,
java.lang.String[] names,
boolean inherited)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException
updateRole
public static Role updateRole(long roleId,
java.lang.String name)
throws com.liferay.portal.PortalException,
com.liferay.portal.SystemException,
java.rmi.RemoteException
- Throws:
com.liferay.portal.PortalException
com.liferay.portal.SystemException
java.rmi.RemoteException