Record Class SensitivityReport.WeightRange

java.lang.Object
java.lang.Record
com.eqixiac.equinix.design.solve.SensitivityReport.WeightRange
Record Components:
objective - the objective id
weight - its current share of the total weight, 0..1
low - the smallest share that keeps the recommendation
high - the largest share that keeps the recommendation
belowTakeover - the portfolio recommended just below low, or null when low is 0
aboveTakeover - the portfolio recommended just above high, or null when high is 1
Enclosing class:
SensitivityReport

public static record SensitivityReport.WeightRange(String objective, double weight, double low, double high, String belowTakeover, String aboveTakeover) extends Record
The range of one objective's share of the total weight over which the recommendation stays the same, the other weights keeping their proportions to each other.
  • Constructor Details

    • WeightRange

      public WeightRange(String objective, double weight, double low, double high, String belowTakeover, String aboveTakeover)
      Creates an instance of a WeightRange record class.
      Parameters:
      objective - the value for the objective record component
      weight - the value for the weight record component
      low - the value for the low record component
      high - the value for the high record component
      belowTakeover - the value for the belowTakeover record component
      aboveTakeover - the value for the aboveTakeover record component
  • 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 the compare method from their corresponding wrapper classes.
      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.
    • objective

      public String objective()
      Returns the value of the objective record component.
      Returns:
      the value of the objective record component
    • weight

      public double weight()
      Returns the value of the weight record component.
      Returns:
      the value of the weight record component
    • low

      public double low()
      Returns the value of the low record component.
      Returns:
      the value of the low record component
    • high

      public double high()
      Returns the value of the high record component.
      Returns:
      the value of the high record component
    • belowTakeover

      public String belowTakeover()
      Returns the value of the belowTakeover record component.
      Returns:
      the value of the belowTakeover record component
    • aboveTakeover

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