Package com.atlassian.jira.mock
Class MockProjectRoleManager.MockRoleActor
java.lang.Object
com.atlassian.jira.mock.MockProjectRoleManager.MockRoleActor
- All Implemented Interfaces:
ProjectRoleActor,RoleActor
- Enclosing class:
MockProjectRoleManager
-
Field Summary
FieldsFields inherited from interface com.atlassian.jira.security.roles.ProjectRoleActor
GROUP_ROLE_ACTOR_TYPE, USER_ROLE_ACTOR_TYPE -
Constructor Summary
ConstructorsConstructorDescriptionMockRoleActor(Long id, Long projectRoleId, Long projectId, Set<ApplicationUser> users, String type, String parameter) -
Method Summary
Modifier and TypeMethodDescriptionbooleancontains(ApplicationUser user) Does this RoleActor contain the specified user.booleanReturns a pretty viewable representation of the contents of the RoleActor (e.g.getId()Returns the id for the Role ActorReturns the string that identifies the target of this role actor (ex.Gets the project this is associated with.This will get the ProjectRole that this RoleActor belongs to.getType()Returns a string that identifies the implementation type.getUsers()Will provide a Set of users encapsulated by this RoleActor.inthashCode()booleanisActive()Whether this Role Actor entity is active or not;voidvoidsetParameter(String parameter) voidsetProjectId(Long projectId) voidsetProjectRoleId(Long projectRoleId) toString()
-
Field Details
-
INVALID_PARAMETER
- See Also:
-
TYPE
- See Also:
-
-
Constructor Details
-
MockRoleActor
public MockRoleActor(Long id, Long projectRoleId, Long projectId, Set<ApplicationUser> users, String type, String parameter) throws RoleActorDoesNotExistException - Throws:
RoleActorDoesNotExistException
-
-
Method Details
-
getId
Description copied from interface:RoleActorReturns the id for the Role Actor -
setId
-
getProjectRoleId
Description copied from interface:RoleActorThis will get the ProjectRole that this RoleActor belongs to.- Specified by:
getProjectRoleIdin interfaceRoleActor- Returns:
- the project role that this instance belongs to.
-
setProjectRoleId
-
getProjectId
Description copied from interface:ProjectRoleActorGets the project this is associated with.- Specified by:
getProjectIdin interfaceProjectRoleActor- Returns:
- project associated with
-
setProjectId
-
getPrettyName
-
getDescriptor
Description copied from interface:RoleActorReturns a pretty viewable representation of the contents of the RoleActor (e.g. if a UserRoleActor, then their full name, James Brown, if a GroupRoleActor, then the name of the group, Business Analysts). NOTE that the returned value is used in RoleActorComparator for sorting.- Specified by:
getDescriptorin interfaceRoleActor- Returns:
- pretty descriptor
-
getType
Description copied from interface:RoleActorReturns a string that identifies the implementation type. This allows us to group common types. -
getParameter
Description copied from interface:RoleActorReturns the string that identifies the target of this role actor (ex. if you are a group role actor, then this will be the unique identifier of the group, the group name).- Specified by:
getParameterin interfaceRoleActor- Returns:
- the target of the role actor
-
getUsers
Description copied from interface:RoleActorWill provide a Set of users encapsulated by this RoleActor. -
setParameter
- Throws:
RoleActorDoesNotExistException
-
contains
Description copied from interface:RoleActorDoes this RoleActor contain the specified user. -
isActive
public boolean isActive()Description copied from interface:RoleActorWhether this Role Actor entity is active or not; -
equals
-
hashCode
public int hashCode() -
toString
-