Record Class DefaultTernaryChartModel.DefaultTernaryPoint
java.lang.Object
java.lang.Record
com.arbergashi.charts.model.DefaultTernaryChartModel.DefaultTernaryPoint
- All Implemented Interfaces:
TernaryChartModel.TernaryPoint
- Enclosing class:
DefaultTernaryChartModel
public static record DefaultTernaryChartModel.DefaultTernaryPoint(double a, double b, double c)
extends Record
implements TernaryChartModel.TernaryPoint
A simple, immutable implementation of TernaryPoint.
- Since:
- 2025-06-01
- Version:
- 1.0.0
- Author:
- Arber Gashi
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultTernaryPoint(double a, double b, double c) Creates an instance of aDefaultTernaryPointrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoublea()Returns the value of thearecord component.doubleb()Returns the value of thebrecord component.doublec()Returns the value of thecrecord component.final booleanIndicates whether some other object is "equal to" this one.doublegetA()doublegetB()doublegetC()final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
DefaultTernaryPoint
public DefaultTernaryPoint(double a, double b, double c) Creates an instance of aDefaultTernaryPointrecord class.- Parameters:
a- the value for thearecord componentb- the value for thebrecord componentc- the value for thecrecord component
-
-
Method Details
-
getA
public double getA()- Specified by:
getAin interfaceTernaryChartModel.TernaryPoint
-
getB
public double getB()- Specified by:
getBin interfaceTernaryChartModel.TernaryPoint
-
getC
public double getC()- Specified by:
getCin interfaceTernaryChartModel.TernaryPoint
-
toString
-
hashCode
-
equals
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 thecomparemethod from their corresponding wrapper classes. -
a
public double a()Returns the value of thearecord component.- Returns:
- the value of the
arecord component
-
b
public double b()Returns the value of thebrecord component.- Returns:
- the value of the
brecord component
-
c
public double c()Returns the value of thecrecord component.- Returns:
- the value of the
crecord component
-