com.silverpeas.workflow.engine.instance
Class WorkingUser

java.lang.Object
  extended by com.silverpeas.workflow.engine.AbstractReferrableObject
      extended by com.silverpeas.workflow.engine.instance.WorkingUser
All Implemented Interfaces:
ReferrableObjectIntf

public class WorkingUser
extends AbstractReferrableObject


Constructor Summary
WorkingUser()
          Default Constructor
 
Method Summary
 String getGroupId()
           
 String getId()
          For persistence in database Get this object id
 String getKey()
          This method has to be implemented by the referrable object it has to compute the unique key
 ProcessInstanceImpl getProcessInstance()
          Get the instance for which user is affected
 String getRole()
          Get state role for which user is affected
 List<String> getRoles()
          Get state role for which user is affected
 String getState()
          Get state name for which user is affected
 String getUserId()
          Get the user id
 String getUsersRole()
          Get the user role
 void setGroupId(String groupId)
           
 void setId(String id)
          For persistence in database Set this object id
 void setProcessInstance(ProcessInstanceImpl processInstance)
          Set the instance for which user is affected
 void setRole(String role)
          Set state role for which user is affected
 void setState(String state)
          Set state name for which user is affected
 void setUserId(String userId)
          Set the user id
 void setUsersRole(String usersRole)
          Set the user role
 Actor toActor()
          Converts WorkingUser to Actor
 Collection<Actor> toActors()
          Converts WorkingUser to Actors
 User toUser()
          Converts WorkingUser to User
static User[] toUser(WorkingUser[] workingUsers)
          Get User information from an array of workingUsers
 
Methods inherited from class com.silverpeas.workflow.engine.AbstractReferrableObject
equals, hashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WorkingUser

public WorkingUser()
Default Constructor

Method Detail

getId

public String getId()
For persistence in database Get this object id

Returns:
this object id

setId

public void setId(String id)
For persistence in database Set this object id

Parameters:
this - object id

getState

public String getState()
Get state name for which user is affected

Returns:
state name

setState

public void setState(String state)
Set state name for which user is affected

Parameters:
state - state name

getRole

public String getRole()
Get state role for which user is affected

Returns:
state role

getRoles

public List<String> getRoles()
Get state role for which user is affected

Returns:
state role

setRole

public void setRole(String role)
Set state role for which user is affected

Parameters:
state - state role

getUserId

public String getUserId()
Get the user id

Returns:
user id

setUserId

public void setUserId(String userId)
Set the user id

Parameters:
userId - user id

getUsersRole

public String getUsersRole()
Get the user role

Returns:
user role name

setUsersRole

public void setUsersRole(String usersRole)
Set the user role

Parameters:
usersRole - role

getGroupId

public String getGroupId()

setGroupId

public void setGroupId(String groupId)

getProcessInstance

public ProcessInstanceImpl getProcessInstance()
Get the instance for which user is affected

Returns:
instance

setProcessInstance

public void setProcessInstance(ProcessInstanceImpl processInstance)
Set the instance for which user is affected

Parameters:
processInstance - instance

toUser

public User toUser()
            throws WorkflowException
Converts WorkingUser to User

Returns:
an object implementing User interface and containing user details
Throws:
WorkflowException

toActor

public Actor toActor()
              throws WorkflowException
Converts WorkingUser to Actor

Returns:
an object implementing Actor interface
Throws:
WorkflowException

toActors

public Collection<Actor> toActors()
                           throws WorkflowException
Converts WorkingUser to Actors

Returns:
an object implementing Actor interface
Throws:
WorkflowException

toUser

public static User[] toUser(WorkingUser[] workingUsers)
                     throws WorkflowException
Get User information from an array of workingUsers

Parameters:
workingUsers - an array of WorkingUser objects
Returns:
an array of objects implementing User interface and containing user details
Throws:
WorkflowException

getKey

public String getKey()
This method has to be implemented by the referrable object it has to compute the unique key

Specified by:
getKey in interface ReferrableObjectIntf
Specified by:
getKey in class AbstractReferrableObject
Returns:
The unique key.
See Also:
equals, hashCode


Copyright © 2016 Silverpeas. All Rights Reserved.