Class UserConfig

    • Constructor Detail

      • UserConfig

        public UserConfig()
    • Method Detail

      • isPortalLogin

        public boolean isPortalLogin()
        Indicates if this user may be logged in normally by the portal's default authenticator.

        Users whose passwords are authenticated externally and should not use the password in the portal database must have this attribute set to false to prevent from being authenticated against the password stored in the portal database.

        Returns:
        if this user may be logged in normally by the portal's default authenticator.
        Since:
        4.0.8
      • setPortalLogin

        public void setPortalLogin​(boolean portalLogin)
        Sets if this user may be logged in normally by the portal's default authenticator.
        Parameters:
        portalLogin - the value to set.
        Since:
        4.0.8
        See Also:
        isPortalLogin()
      • getOrigin

        public java.lang.String getOrigin()
        Returns the origin of this user. The origin is used to identify from where the user was added, for example, was imported from an external repository.
        Returns:
        the origin of this user. null indicates the user was added normally.
        Since:
        4.0.8
      • setOrigin

        public void setOrigin​(java.lang.String origin)
        Sets the origin for this user.
        Parameters:
        origin - the origin to set.
        Since:
        4.0.8
        See Also:
        getOrigin()
      • isDisabled

        public boolean isDisabled()
      • setDisabled

        public void setDisabled​(boolean disabled)
      • getEmail

        @Deprecated
        public java.lang.String getEmail()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getEmail().
      • setEmail

        @Deprecated
        public void setEmail​(java.lang.String email)
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().setEmail().
      • getFirstName

        @Deprecated
        public java.lang.String getFirstName()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getFirstName().
      • setFirstName

        @Deprecated
        public void setFirstName​(java.lang.String firstName)
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().setFirstName().
      • getId

        public java.lang.String getId()
      • setId

        public void setId​(java.lang.String id)
      • getLastName

        @Deprecated
        public java.lang.String getLastName()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getLastName().
      • setLastName

        @Deprecated
        public void setLastName​(java.lang.String lastName)
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().setLastName().
      • getLogin

        public java.lang.String getLogin()
      • setLogin

        public void setLogin​(java.lang.String login)
      • getMiddleName

        @Deprecated
        public java.lang.String getMiddleName()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getMiddleName().
      • setMiddleName

        @Deprecated
        public void setMiddleName​(java.lang.String middleName)
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().setMiddleName().
      • isMultiSession

        public boolean isMultiSession()
      • setMultiSession

        public void setMultiSession​(boolean multiSession)
      • getPassword

        public java.lang.String getPassword()
      • setPassword

        public void setPassword​(java.lang.String password)
      • getType

        public int getType()
      • setType

        public void setType​(int type)
      • getChannelId

        public java.lang.String getChannelId()
      • setChannelId

        public void setChannelId​(java.lang.String channelId)
      • getProfileImageHref

        public java.lang.String getProfileImageHref()
        Returns the href of this user profile image.
        Returns:
        the href of this user profile image.
        Since:
        8.0.0
      • setProfileImage

        public void setProfileImage​(java.io.InputStream imageStream,
                                    java.lang.String mimeType)
                             throws PortalException
        Sets the profile image of the given user.
        Parameters:
        imageStream - an input stream of the image to set, or null if the current profile image, if any, is to be deleted. This stream will be consumed but not closed by this method.
        mimeType - the MIME type of the image. This parameter is ignored if imageStream is null.
        Throws:
        java.lang.IllegalArgumentException - if the image stream parameter is not null and the mime type parameter is null.
        PortalException - if other error occur.
        Since:
        8.0.0
      • getFullName

        @Deprecated
        public java.lang.String getFullName()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getFullName().
      • getLastLogin

        public java.util.Date getLastLogin()
        Returns the date and time of last login for this user.
        Returns:
        the date, or null if this user never logged in.
        Since:
        6.2.0
      • getCustomAttributes

        @Deprecated
        public java.util.Map<java.lang.String,​java.lang.Object> getCustomAttributes()
        Deprecated.
        Since 12.0.0, due to introduction of trusted and untrusted properties, replaced by getTrustedProperties().getCustomAttributes().
        Returns a map with the values of custom attributes of this user. To modify the value of custom attributes of this user, the returned map may be modified and the changes will be persisted when IUserManager.update(lumis.portal.authentication.SessionConfig, UserConfig, ITransaction) is called, like other user properties.
        Returns:
        a map where the key of the map is the attribute identifier and the value of the map is the attribute value, with a type that corresponds to the attribute data type.
        Since:
        11.0.0
      • getVisitorId

        public long getVisitorId()
        Returns the visitor identifier of this user.
        Returns:
        the visitor identifier.
        Throws:
        java.lang.IllegalStateException - if this user was not persisted or obtained using IUserManager, so its visitor identifier was not generated, or if this user is the special guest user.
        Since:
        12.0.0
      • getFriendlyId

        public java.lang.String getFriendlyId()
        Returns the friendly identifier of this user.
        Returns:
        the friendly identifier.
        Since:
        12.0.0
      • getTrustedProperties

        public IUserProperties getTrustedProperties()
        Returns this user's trusted properties. The trusted properties represents properties provided by trusted sources such as an authenticated user and always overwrites any corresponding untrusted property.
        Returns:
        the trusted properties.
        Since:
        12.0.0
        See Also:
        getUntrustedProperties(), getProperties()
      • getUntrustedProperties

        public IUserProperties getUntrustedProperties()
        Returns this user's untrusted properties. The untrusted properties represents properties provided by untrusted sources such as unauthenticated information collected by user monitoring. It is always overwritten by corresponding untrusted property.
        Returns:
        the untrusted properties.
        Since:
        12.0.0
        See Also:
        getTrustedProperties(), getProperties()
      • getProperties

        public IUserPropertiesReadOnly getProperties()
        Returns a read-only view of this user's properties, merging trusted and untrusted properties.
        Returns:
        the properties.
        Since:
        12.0.0