Class ActorImpl

  • All Implemented Interfaces:
    Actor
    Direct Known Subclasses:
    ParticipantImpl

    public class ActorImpl
    extends Object
    implements Actor
    A Actor object represents a person or a list of persons (through role or group) that can act on a state
    • Constructor Detail

      • ActorImpl

        public ActorImpl​(User user,
                         String userRoleName,
                         State state)
        Constructor of an actor.
        Parameters:
        user - user aka the actor
        userRoleName - name of the role under which the user was/may be an actor
        state - state for which the user was/may be an actor
    • Method Detail

      • getUser

        public User getUser()
        Returns the actor as a User object
        Specified by:
        getUser in interface Actor
      • getUserRoleName

        public String getUserRoleName()
        get the name of the role under which the user was/may be an actor
        Specified by:
        getUserRoleName in interface Actor
        Returns:
        the role's name
      • getState

        public State getState()
        get the name of the state for which the user was/may be an actor
        Specified by:
        getState in interface Actor
        Returns:
        the state as a State object