Record Class SqlIndexMapping

java.lang.Object
java.lang.Record
io.micronaut.data.model.schema.sql.SqlIndexMapping
Record Components:
name - The index name
unique - Whether the index is unique
columns - The column names in the index

@Internal public record SqlIndexMapping(String name, boolean unique, String[] columns) extends Record
The SQL table index mapping.
  • Constructor Summary

    Constructors
    Constructor
    Description
    SqlIndexMapping(String name, boolean unique, String[] columns)
    Creates an instance of a SqlIndexMapping record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the columns record component.
    boolean
    equals(Object object)
    Indicates whether some other object is "equal to" this one.
    int
    Returns a hash code value for this object.
    Returns the value of the name record component.
    Returns a string representation of this record class.
    boolean
    Returns the value of the unique record component.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • SqlIndexMapping

      public SqlIndexMapping(String name, boolean unique, String[] columns)
      Creates an instance of a SqlIndexMapping record class.
      Parameters:
      name - the value for the name record component
      unique - the value for the unique record component
      columns - the value for the columns record component
  • Method Details

    • equals

      public boolean equals(Object object)
      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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      object - the object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise.
    • hashCode

      public 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
    • toString

      public String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • unique

      public boolean unique()
      Returns the value of the unique record component.
      Returns:
      the value of the unique record component
    • columns

      public String[] columns()
      Returns the value of the columns record component.
      Returns:
      the value of the columns record component