Record Class OracleReturningMetadata

java.lang.Object
java.lang.Record
io.micronaut.data.runtime.operations.internal.sql.OracleReturningMetadata
Record Components:
canonicalColumnIndexesByName - The canonical returned column names mapped to the underlying JDBC/R2DBC index
columnIndexesByName - The canonical names plus Oracle-specific aliases mapped to the same underlying index

@Internal public record OracleReturningMetadata(Map<String,Integer> canonicalColumnIndexesByName, Map<String,Integer> columnIndexesByName) extends Record
Oracle SQL RETURNING column metadata with both canonical and alias-expanded views.
Since:
5.0
Author:
Radovan Radic
  • Constructor Details

    • OracleReturningMetadata

      public OracleReturningMetadata(Map<String,Integer> canonicalColumnIndexesByName, Map<String,Integer> columnIndexesByName)
      Creates an instance of a OracleReturningMetadata record class.
      Parameters:
      canonicalColumnIndexesByName - the value for the canonicalColumnIndexesByName record component
      columnIndexesByName - the value for the columnIndexesByName record component
  • Method Details

    • create

      public static OracleReturningMetadata create(List<String> columnNames)
      Creates Oracle RETURNING metadata using zero-based positions derived from the provided column order.
      Parameters:
      columnNames - The returned column names in result order
      Returns:
      The Oracle returning metadata
    • create

      public static OracleReturningMetadata create(List<String> columnNames, List<Integer> columnIndexes)
      Creates Oracle RETURNING metadata using the provided column order and underlying indexes.
      Parameters:
      columnNames - The returned column names in result order
      columnIndexes - The underlying JDBC/R2DBC indexes for each returned column
      Returns:
      The Oracle returning metadata
    • toString

      public final 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
    • 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.
    • canonicalColumnIndexesByName

      public Map<String,Integer> canonicalColumnIndexesByName()
      Returns the value of the canonicalColumnIndexesByName record component.
      Returns:
      the value of the canonicalColumnIndexesByName record component
    • columnIndexesByName

      public Map<String,Integer> columnIndexesByName()
      Returns the value of the columnIndexesByName record component.
      Returns:
      the value of the columnIndexesByName record component