Class UserDataTemplate

java.lang.Object
com.aquima.interactions.test.templates.process.UserDataTemplate
All Implemented Interfaces:
com.aquima.interactions.project.IUserData, Serializable

public class UserDataTemplate extends Object implements com.aquima.interactions.project.IUserData
Template class that may be used to initialize user data.
Since:
7.1
Author:
Jon van Leuven
See Also:
  • Constructor Details

    • UserDataTemplate

      public UserDataTemplate()
      Default constructor that creates a user with no roles user ID 'userId' and name 'userName'.
  • Method Details

    • setUserId

      public UserDataTemplate setUserId(String userId)
      This method sets the user identifier.
      Parameters:
      userId - The user identifier.
    • setUserName

      public UserDataTemplate setUserName(String userName)
      This method sets the user name.
      Parameters:
      userName - The user name.
    • setTenant

      public UserDataTemplate setTenant(String tenant)
      This method sets the tenant.
      Parameters:
      tenant - The tenant.
    • addRole

      public UserDataTemplate addRole(String roleName)
      This method adds a role based on a role name.
      Parameters:
      roleName - The role name.
    • addRoles

      public UserDataTemplate addRoles(String... roleNames)
      Adds the given roles to this user.
      Parameters:
      roleNames - the names of the roles
      Returns:
      this object for method chaining
    • addTeam

      public UserDataTemplate addTeam(String teamName)
      This method adds a team based on a team name.
      Parameters:
      teamName - The team name.
    • addTeams

      public UserDataTemplate addTeams(String... teamNames)
      Adds the given teams to this user.
      Parameters:
      teamNames - the names of the teams
      Returns:
      this object for method chaining
    • getRoles

      public String[] getRoles()
      Specified by:
      getRoles in interface com.aquima.interactions.project.IUserData
    • getTeams

      public String[] getTeams()
      Specified by:
      getTeams in interface com.aquima.interactions.project.IUserData
    • getTenant

      public String getTenant()
      Specified by:
      getTenant in interface com.aquima.interactions.project.IUserData
    • addCustomProperty

      public void addCustomProperty(String key, String value)
      Specified by:
      addCustomProperty in interface com.aquima.interactions.project.IUserData
    • getCustomProperty

      public String getCustomProperty(String name)
      Specified by:
      getCustomProperty in interface com.aquima.interactions.project.IUserData
    • hasCustomProperty

      public boolean hasCustomProperty(String name)
      Specified by:
      hasCustomProperty in interface com.aquima.interactions.project.IUserData
    • getCustomPropertyNames

      public String[] getCustomPropertyNames()
      Specified by:
      getCustomPropertyNames in interface com.aquima.interactions.project.IUserData
    • setHeader

      public void setHeader(String name, List<String> values)
      Specified by:
      setHeader in interface com.aquima.interactions.project.IUserData
    • getHeader

      public List<String> getHeader(String name)
      Specified by:
      getHeader in interface com.aquima.interactions.project.IUserData
    • getHeaderNames

      public Set<String> getHeaderNames()
      Specified by:
      getHeaderNames in interface com.aquima.interactions.project.IUserData
    • setAuthenticationClaim

      public void setAuthenticationClaim(String name, List<String> values)
      Specified by:
      setAuthenticationClaim in interface com.aquima.interactions.project.IUserData
    • getAuthenticationClaim

      public List<String> getAuthenticationClaim(String name)
      Specified by:
      getAuthenticationClaim in interface com.aquima.interactions.project.IUserData
    • getAuthenticationClaimNames

      public Set<String> getAuthenticationClaimNames()
      Specified by:
      getAuthenticationClaimNames in interface com.aquima.interactions.project.IUserData
    • getUserId

      public String getUserId()
      Specified by:
      getUserId in interface com.aquima.interactions.project.IUserData
    • getUserName

      public String getUserName()
      Specified by:
      getUserName in interface com.aquima.interactions.project.IUserData
    • isAnonymous

      public boolean isAnonymous()
      Specified by:
      isAnonymous in interface com.aquima.interactions.project.IUserData
    • isAutomatic

      public boolean isAutomatic()
      Specified by:
      isAutomatic in interface com.aquima.interactions.project.IUserData