Class User.Builder

  • Enclosing class:
    User

    public static class User.Builder
    extends Object
    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • id

        public User.Builder id​(String id)
        The OCID of the user.
        Parameters:
        id - the value to set
        Returns:
        this builder
      • compartmentId

        public User.Builder compartmentId​(String compartmentId)
        The OCID of the tenancy containing the user.
        Parameters:
        compartmentId - the value to set
        Returns:
        this builder
      • name

        public User.Builder name​(String name)
        The name you assign to the user during creation.

        This is the user’s login for the Console. The name must be unique across all users in the tenancy and cannot be changed.

        Parameters:
        name - the value to set
        Returns:
        this builder
      • description

        public User.Builder description​(String description)
        The description you assign to the user.

        Does not have to be unique, and it’s changeable.

        (For tenancies that support identity domains) You can have an empty description.

        Parameters:
        description - the value to set
        Returns:
        this builder
      • email

        public User.Builder email​(String email)
        The email address you assign to the user.

        The email address must be unique across all users in the tenancy.

        (For tenancies that support identity domains) The email address is required unless the requirement is disabled at the tenancy level.

        Parameters:
        email - the value to set
        Returns:
        this builder
      • emailVerified

        public User.Builder emailVerified​(Boolean emailVerified)
        Whether the email address has been validated.
        Parameters:
        emailVerified - the value to set
        Returns:
        this builder
      • dbUserName

        public User.Builder dbUserName​(String dbUserName)
        DB username of the DB credential.

        Has to be unique across the tenancy.

        Parameters:
        dbUserName - the value to set
        Returns:
        this builder
      • identityProviderId

        public User.Builder identityProviderId​(String identityProviderId)
        The OCID of the IdentityProvider this user belongs to.
        Parameters:
        identityProviderId - the value to set
        Returns:
        this builder
      • externalIdentifier

        public User.Builder externalIdentifier​(String externalIdentifier)
        Identifier of the user in the identity provider
        Parameters:
        externalIdentifier - the value to set
        Returns:
        this builder
      • timeCreated

        public User.Builder timeCreated​(Date timeCreated)
        Date and time the user was created, in the format defined by RFC3339.

        Example: 2016-08-25T21:10:29.600Z

        Parameters:
        timeCreated - the value to set
        Returns:
        this builder
      • lifecycleState

        public User.Builder lifecycleState​(User.LifecycleState lifecycleState)
        The user’s current state.

        After creating a user, make sure its lifecycleState changes from CREATING to ACTIVE before using it.

        Parameters:
        lifecycleState - the value to set
        Returns:
        this builder
      • inactiveStatus

        public User.Builder inactiveStatus​(Long inactiveStatus)
        Returned only if the user’s lifecycleState is INACTIVE.

        A 16-bit value showing the reason why the user is inactive:

        - bit 0: SUSPENDED (reserved for future use) - bit 1: DISABLED (reserved for future use) - bit 2: BLOCKED (the user has exceeded the maximum number of failed login attempts for the Console)

        Parameters:
        inactiveStatus - the value to set
        Returns:
        this builder
      • freeformTags

        public User.Builder freeformTags​(Map<String,​String> freeformTags)
        Free-form tags for this resource.

        Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.

        Example: {"Department": "Finance"}

        Parameters:
        freeformTags - the value to set
        Returns:
        this builder
      • definedTags

        public User.Builder definedTags​(Map<String,​Map<String,​Object>> definedTags)
        Defined tags for this resource.

        Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {“Operations”: {“CostCenter”: “42”}}

        Parameters:
        definedTags - the value to set
        Returns:
        this builder
      • isMfaActivated

        public User.Builder isMfaActivated​(Boolean isMfaActivated)
        Flag indicates if MFA has been activated for the user.
        Parameters:
        isMfaActivated - the value to set
        Returns:
        this builder
      • lastSuccessfulLoginTime

        public User.Builder lastSuccessfulLoginTime​(Date lastSuccessfulLoginTime)
        The date and time of when the user most recently logged in the format defined by RFC3339 (ex.

        2016-08-25T21:10:29.600Z). If there is no login history, this field is null.

        For illustrative purposes, suppose we have a user who has logged in at July 1st, 2020 at 1200 PST and logged out 30 minutes later. They then login again on July 2nd, 2020 at 1500 PST.

        Their previousSuccessfulLoginTime would be 2020-07-01:19:00.000Z.

        Their lastSuccessfulLoginTime would be 2020-07-02:22:00.000Z.

        Parameters:
        lastSuccessfulLoginTime - the value to set
        Returns:
        this builder
      • previousSuccessfulLoginTime

        public User.Builder previousSuccessfulLoginTime​(Date previousSuccessfulLoginTime)
        The date and time of when the user most recently logged in the format defined by RFC3339 (ex.

        2016-08-25T21:10:29.600Z). If there is no login history, this field is null.

        For illustrative purposes, suppose we have a user who has logged in at July 1st, 2020 at 1200 PST and logged out 30 minutes later. They then login again on July 2nd, 2020 at 1500 PST.

        Their previousSuccessfulLoginTime would be 2020-07-01:19:00.000Z.

        Their lastSuccessfulLoginTime would be 2020-07-02:22:00.000Z.

        Parameters:
        previousSuccessfulLoginTime - the value to set
        Returns:
        this builder
      • build

        public User build()