Package kr.toxicity.model.api.animation
Record Class VectorPoint
java.lang.Object
java.lang.Record
kr.toxicity.model.api.animation.VectorPoint
- Record Components:
function- functiontime- timeinterpolator- interpolator
- All Implemented Interfaces:
Comparable<Timed>,Timed
public record VectorPoint(@NotNull FloatFunction<org.joml.Vector3f> function, float time, @NotNull VectorPoint.BezierConfig bezier, @NotNull VectorInterpolator interpolator)
extends Record
implements Timed
Vector point
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionVectorPoint(@NotNull FloatFunction<org.joml.Vector3f> function, float time, @NotNull VectorPoint.BezierConfig bezier, @NotNull VectorInterpolator interpolator) Creates an instance of aVectorPointrecord class. -
Method Summary
Modifier and TypeMethodDescription@NotNull VectorPoint.BezierConfigbezier()Returns the value of thebezierrecord component.booleanIndicates whether some other object is "equal to" this one.@NotNull FloatFunction<org.joml.Vector3f> function()Returns the value of thefunctionrecord component.inthashCode()Returns a hash code value for this object.@NotNull VectorInterpolatorReturns the value of theinterpolatorrecord component.booleanChecks this vector point is continuousfloattime()Returns the value of thetimerecord component.final StringtoString()Returns a string representation of this record class.@NotNull org.joml.Vector3fvector()Gets vector@NotNull org.joml.Vector3fvector(float time) Gets vector by time
-
Field Details
-
EMPTY
Empty point
-
-
Constructor Details
-
VectorPoint
public VectorPoint(@NotNull @NotNull FloatFunction<org.joml.Vector3f> function, float time, @NotNull @NotNull VectorPoint.BezierConfig bezier, @NotNull @NotNull VectorInterpolator interpolator) Creates an instance of aVectorPointrecord class.- Parameters:
function- the value for thefunctionrecord componenttime- the value for thetimerecord componentbezier- the value for thebezierrecord componentinterpolator- the value for theinterpolatorrecord component
-
-
Method Details
-
vector
@NotNull public @NotNull org.joml.Vector3f vector(float time) Gets vector by time- Parameters:
time- time- Returns:
- vector
-
isContinuous
public boolean isContinuous()Checks this vector point is continuous- Returns:
- is continuous
-
vector
@NotNull public @NotNull org.joml.Vector3f vector()Gets vector- Returns:
- vector
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
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. -
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. -
function
Returns the value of thefunctionrecord component.- Returns:
- the value of the
functionrecord component
-
time
public float time()Returns the value of thetimerecord component. -
bezier
Returns the value of thebezierrecord component.- Returns:
- the value of the
bezierrecord component
-
interpolator
Returns the value of theinterpolatorrecord component.- Returns:
- the value of the
interpolatorrecord component
-