Class VirtualUser

  • All Implemented Interfaces:
    IUser, Serializable

    public class VirtualUser
    extends Object
    implements IUser
    Model for virtual users such as the SYSTEM user.
    Since:
    8.0.0
    Author:
    XIMA Media GmbH
    See Also:
    Serialized Form
    • Field Detail

      • SYSTEM

        public static final IUser SYSTEM
      • ANONYMOUS

        public static final IUser ANONYMOUS
    • Method Detail

      • getAuthenticationContext

        public IAuthenticationContext getAuthenticationContext()
        Specified by:
        getAuthenticationContext in interface IUser
        Returns:
        the authentication context for this user. The authentication context contains information about how the user authenticated. Virtual users don't have an authentication context because they have never been authenticated.
      • getEmail

        public String getEmail()
        Specified by:
        getEmail in interface IUser
        Returns:
        the email address of the user if there is any. The email address may come from the formcycle profile or the profile returned by the authentication client.
      • getUserName

        public String getUserName()
        Specified by:
        getUserName in interface IUser
        Returns:
        the user name of this user within the formcycle system if there is any and null otherwise.
      • getFirstName

        public String getFirstName()
        Specified by:
        getFirstName in interface IUser
        Returns:
        the first name of the user if there is any. The first name may come from the formcycle profile or the profile returned by the authentication client.
      • getFamilyName

        public String getFamilyName()
        Specified by:
        getFamilyName in interface IUser
        Returns:
        the family name of the user if there is any. The family name may come from the formcycle profile or the profile returned by the authentication client.
      • getDisplayName

        public String getDisplayName()
        Specified by:
        getDisplayName in interface IUser
        Returns:
        the display name of the user if there is any. The display name may come from the formcycle profile or the profile returned by the authentication client and is usually the full name (first and family name separated by whitespace).
      • getGender

        public EGender getGender()
        Specified by:
        getGender in interface IUser
        Returns:
        the gender of the user if there is any specified and EGender.UNSPECIFIED otherwise. The gender may come from the formcycle profile or the profile returned by the authentication client.
      • getPictureUrl

        public URI getPictureUrl()
        Specified by:
        getPictureUrl in interface IUser
        Returns:
        the picture URL of the user if there is any and null otherwise. The picture URL may come from the profile returned by the authentication client.
      • getProfile

        public UserProfile getProfile()
        Specified by:
        getProfile in interface IUser
        Returns:
        the formcycle profile of the user if a match was found in the system and null otherwise.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object