Class ContactMethod

    • Method Detail

      • contactEndpoint

        public final String contactEndpoint()

        The destination of the contact method, such as an email address or a mobile phone number.

        Returns:
        The destination of the contact method, such as an email address or a mobile phone number.
      • status

        public final ContactMethodStatus status()

        The current status of the contact method.

        A contact method has the following possible status:

        • PendingVerification - The contact method has not yet been verified, and the verification has not yet expired.

        • Valid - The contact method has been verified.

        • InValid - An attempt was made to verify the contact method, but the verification has expired.

        If the service returns an enum value that is not available in the current SDK version, status will return ContactMethodStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from statusAsString().

        Returns:
        The current status of the contact method.

        A contact method has the following possible status:

        • PendingVerification - The contact method has not yet been verified, and the verification has not yet expired.

        • Valid - The contact method has been verified.

        • InValid - An attempt was made to verify the contact method, but the verification has expired.

        See Also:
        ContactMethodStatus
      • statusAsString

        public final String statusAsString()

        The current status of the contact method.

        A contact method has the following possible status:

        • PendingVerification - The contact method has not yet been verified, and the verification has not yet expired.

        • Valid - The contact method has been verified.

        • InValid - An attempt was made to verify the contact method, but the verification has expired.

        If the service returns an enum value that is not available in the current SDK version, status will return ContactMethodStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from statusAsString().

        Returns:
        The current status of the contact method.

        A contact method has the following possible status:

        • PendingVerification - The contact method has not yet been verified, and the verification has not yet expired.

        • Valid - The contact method has been verified.

        • InValid - An attempt was made to verify the contact method, but the verification has expired.

        See Also:
        ContactMethodStatus
      • protocolAsString

        public final String protocolAsString()

        The protocol of the contact method, such as email or SMS (text messaging).

        If the service returns an enum value that is not available in the current SDK version, protocol will return ContactProtocol.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from protocolAsString().

        Returns:
        The protocol of the contact method, such as email or SMS (text messaging).
        See Also:
        ContactProtocol
      • name

        public final String name()

        The name of the contact method.

        Returns:
        The name of the contact method.
      • arn

        public final String arn()

        The Amazon Resource Name (ARN) of the contact method.

        Returns:
        The Amazon Resource Name (ARN) of the contact method.
      • createdAt

        public final Instant createdAt()

        The timestamp when the contact method was created.

        Returns:
        The timestamp when the contact method was created.
      • location

        public final ResourceLocation location()

        An object that describes the location of the contact method, such as the Amazon Web Services Region and Availability Zone.

        Returns:
        An object that describes the location of the contact method, such as the Amazon Web Services Region and Availability Zone.
      • supportCode

        public final String supportCode()

        The support code. Include this code in your email to support when you have questions about your Lightsail contact method. This code enables our support team to look up your Lightsail information more easily.

        Returns:
        The support code. Include this code in your email to support when you have questions about your Lightsail contact method. This code enables our support team to look up your Lightsail information more easily.
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class Object
      • equals

        public final boolean equals​(Object obj)
        Overrides:
        equals in class Object
      • toString

        public final String toString()
        Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
        Overrides:
        toString in class Object
      • getValueForField

        public final <T> Optional<T> getValueForField​(String fieldName,
                                                      Class<T> clazz)