Record Class LossReport

java.lang.Object
java.lang.Record
com.pain001.sdk.LossReport
Record Components:
face - the face name
totalSourceElements - leaves in the source document
mappedCount - leaves the projection carried
unmappedCount - leaves it did not carry
isLossless - whether every leaf was carried
lossRatio - the share of source leaves not carried
mappedPaths - the carried paths
unmappedPaths - the paths not carried

public record LossReport(String face, int totalSourceElements, int mappedCount, int unmappedCount, boolean isLossless, double lossRatio, List<String> mappedPaths, List<String> unmappedPaths) extends Record
What a face projection carried and what it did not, by indexed path.
  • Constructor Details

    • LossReport

      public LossReport(String face, int totalSourceElements, int mappedCount, int unmappedCount, boolean isLossless, double lossRatio, List<String> mappedPaths, List<String> unmappedPaths)
      Copies the lists so the record stays immutable.
  • Method Details

    • 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • face

      public String face()
      Returns the value of the face record component.
      Returns:
      the value of the face record component
    • totalSourceElements

      public int totalSourceElements()
      Returns the value of the totalSourceElements record component.
      Returns:
      the value of the totalSourceElements record component
    • mappedCount

      public int mappedCount()
      Returns the value of the mappedCount record component.
      Returns:
      the value of the mappedCount record component
    • unmappedCount

      public int unmappedCount()
      Returns the value of the unmappedCount record component.
      Returns:
      the value of the unmappedCount record component
    • isLossless

      public boolean isLossless()
      Returns the value of the isLossless record component.
      Returns:
      the value of the isLossless record component
    • lossRatio

      public double lossRatio()
      Returns the value of the lossRatio record component.
      Returns:
      the value of the lossRatio record component
    • mappedPaths

      public List<String> mappedPaths()
      Returns the value of the mappedPaths record component.
      Returns:
      the value of the mappedPaths record component
    • unmappedPaths

      public List<String> unmappedPaths()
      Returns the value of the unmappedPaths record component.
      Returns:
      the value of the unmappedPaths record component