com.dotmarketing.factories
Class RoleFactory

java.lang.Object
  extended by com.dotmarketing.factories.RoleFactory

public class RoleFactory
extends java.lang.Object

Author:
maria

Constructor Summary
RoleFactory()
           
 
Method Summary
static void createDefaultRoles()
           
static java.util.List<Role> getAllRolesForUser(java.lang.String userId)
           
static Role getCMSAdministratorRole()
           
static Role getRoleById(java.lang.String roleId)
           
static Role getRoleByName(java.lang.String roleName)
           
static java.util.Set<User> getUsers(java.lang.String roleId)
           
static boolean userHasRole(User user, java.lang.String roleName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RoleFactory

public RoleFactory()
Method Detail

createDefaultRoles

public static void createDefaultRoles()

getRoleByName

public static Role getRoleByName(java.lang.String roleName)

getRoleById

public static Role getRoleById(java.lang.String roleId)
                        throws NoSuchRoleException
Throws:
NoSuchRoleException

getAllRolesForUser

public static java.util.List<Role> getAllRolesForUser(java.lang.String userId)

getUsers

public static java.util.Set<User> getUsers(java.lang.String roleId)

getCMSAdministratorRole

public static Role getCMSAdministratorRole()

userHasRole

public static boolean userHasRole(User user,
                                  java.lang.String roleName)


Copyright © 2006 Dotmarketing, Inc. All Rights Reserved.