Record Class OttDestination

java.lang.Object
java.lang.Record
com.irurueta.authserver.authorization.application.ott.OttDestination
Record Components:
userId - identifier of the user.
channel - the channel.
address - the e-mail address or the E.164 phone number.

public record OttDestination(UUID userId, OttChannel channel, String address) extends Record
Where a one-time code of a user is delivered.
  • Field Details

    • userId

      private final UUID userId
      The field for the userId record component.
    • channel

      private final OttChannel channel
      The field for the channel record component.
    • address

      private final String address
      The field for the address record component.
  • Constructor Details

  • Method Details

    • toString

      public String toString()
      Describes the destination without the address, so it never reaches a log.
      Specified by:
      toString in class Record
      Returns:
      the description.
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • userId

      public UUID userId()
      Returns the value of the userId record component.
      Returns:
      the value of the userId record component
    • channel

      public OttChannel channel()
      Returns the value of the channel record component.
      Returns:
      the value of the channel record component
    • address

      public String address()
      Returns the value of the address record component.
      Returns:
      the value of the address record component