Class Session.Builder

  • Enclosing class:
    Session

    public static class Session.Builder
    extends Object
    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • id

        public Session.Builder id​(String id)
        The unique identifier (OCID) of the session, which can’t be changed after creation.
        Parameters:
        id - the value to set
        Returns:
        this builder
      • displayName

        public Session.Builder displayName​(String displayName)
        The name of the session.
        Parameters:
        displayName - the value to set
        Returns:
        this builder
      • bastionId

        public Session.Builder bastionId​(String bastionId)
        The unique identifier (OCID) of the bastion that is hosting this session.
        Parameters:
        bastionId - the value to set
        Returns:
        this builder
      • bastionName

        public Session.Builder bastionName​(String bastionName)
        The name of the bastion that is hosting this session.
        Parameters:
        bastionName - the value to set
        Returns:
        this builder
      • bastionUserName

        public Session.Builder bastionUserName​(String bastionUserName)
        The username that the session uses to connect to the target resource.
        Parameters:
        bastionUserName - the value to set
        Returns:
        this builder
      • sshMetadata

        public Session.Builder sshMetadata​(Map<String,​String> sshMetadata)
        The connection message for the session.
        Parameters:
        sshMetadata - the value to set
        Returns:
        this builder
      • keyType

        public Session.Builder keyType​(Session.KeyType keyType)
        The type of the key used to connect to the session.

        PUB is a standard public key in OpenSSH format.

        Parameters:
        keyType - the value to set
        Returns:
        this builder
      • bastionPublicHostKeyInfo

        public Session.Builder bastionPublicHostKeyInfo​(String bastionPublicHostKeyInfo)
        The public key of the bastion host.

        You can use this to verify that you’re connecting to the correct bastion.

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

        public Session.Builder timeCreated​(Date timeCreated)
        The time the session was created.

        Format is defined by RFC3339. Example: 2020-01-25T21:10:29.600Z

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

        public Session.Builder timeUpdated​(Date timeUpdated)
        The time the session was updated.

        Format is defined by RFC3339. Example: 2020-01-25T21:10:29.600Z

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

        public Session.Builder lifecycleState​(SessionLifecycleState lifecycleState)
        The current state of the session.
        Parameters:
        lifecycleState - the value to set
        Returns:
        this builder
      • lifecycleDetails

        public Session.Builder lifecycleDetails​(String lifecycleDetails)
        A message describing the current session state in more detail.
        Parameters:
        lifecycleDetails - the value to set
        Returns:
        this builder
      • sessionTtlInSeconds

        public Session.Builder sessionTtlInSeconds​(Integer sessionTtlInSeconds)
        The amount of time the session can remain active.
        Parameters:
        sessionTtlInSeconds - the value to set
        Returns:
        this builder