Package dev.gothickit.zenkit.ani
Record Class CachedModelAnimation
java.lang.Object
java.lang.Record
dev.gothickit.zenkit.ani.CachedModelAnimation
- All Implemented Interfaces:
ModelAnimation,CacheableObject<CachedModelAnimation>
public record CachedModelAnimation(@NotNull String name, @NotNull String next, int layer, int frameCount, int nodeCount, float fps, float fpsSource, @NotNull AxisAlignedBoundingBox bbox, long checksum, @NotNull String sourcePath, @NotNull Calendar sourceDate, @NotNull String sourceScript, @NotNull List<@NotNull AnimationSample> samples, int @NotNull [] nodeIndices)
extends Record
implements ModelAnimation
-
Constructor Summary
ConstructorsConstructorDescriptionCachedModelAnimation(@NotNull String name, @NotNull String next, int layer, int frameCount, int nodeCount, float fps, float fpsSource, @NotNull AxisAlignedBoundingBox bbox, long checksum, @NotNull String sourcePath, @NotNull Calendar sourceDate, @NotNull String sourceScript, @NotNull List<@NotNull AnimationSample> samples, int @NotNull [] nodeIndices) Creates an instance of aCachedModelAnimationrecord class. -
Method Summary
Modifier and TypeMethodDescription@NotNull AxisAlignedBoundingBoxbbox()Returns the value of thebboxrecord component.@NotNull CachedModelAnimationcache()longchecksum()Returns the value of thechecksumrecord component.final booleanIndicates whether some other object is "equal to" this one.floatfps()Returns the value of thefpsrecord component.floatReturns the value of thefpsSourcerecord component.intReturns the value of theframeCountrecord component.final inthashCode()Returns a hash code value for this object.booleanisCached()intlayer()Returns the value of thelayerrecord component.@NotNull Stringname()Returns the value of thenamerecord component.@NotNull Stringnext()Returns the value of thenextrecord component.intReturns the value of thenodeCountrecord component.int @NotNull []Returns the value of thenodeIndicesrecord component.@Nullable AnimationSamplesample(long i) long@NotNull List<@NotNull AnimationSample>samples()Returns the value of thesamplesrecord component.@NotNull CalendarReturns the value of thesourceDaterecord component.@NotNull StringReturns the value of thesourcePathrecord component.@NotNull StringReturns the value of thesourceScriptrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CachedModelAnimation
public CachedModelAnimation(@NotNull @NotNull String name, @NotNull @NotNull String next, int layer, int frameCount, int nodeCount, float fps, float fpsSource, @NotNull @NotNull AxisAlignedBoundingBox bbox, long checksum, @NotNull @NotNull String sourcePath, @NotNull @NotNull Calendar sourceDate, @NotNull @NotNull String sourceScript, @NotNull @NotNull List<@NotNull AnimationSample> samples, int @NotNull [] nodeIndices) Creates an instance of aCachedModelAnimationrecord class.- Parameters:
name- the value for thenamerecord componentnext- the value for thenextrecord componentlayer- the value for thelayerrecord componentframeCount- the value for theframeCountrecord componentnodeCount- the value for thenodeCountrecord componentfps- the value for thefpsrecord componentfpsSource- the value for thefpsSourcerecord componentbbox- the value for thebboxrecord componentchecksum- the value for thechecksumrecord componentsourcePath- the value for thesourcePathrecord componentsourceDate- the value for thesourceDaterecord componentsourceScript- the value for thesourceScriptrecord componentsamples- the value for thesamplesrecord componentnodeIndices- the value for thenodeIndicesrecord component
-
-
Method Details
-
sampleCount
public long sampleCount()- Specified by:
sampleCountin interfaceModelAnimation
-
sample
- Specified by:
samplein interfaceModelAnimation
-
cache
- Specified by:
cachein interfaceCacheableObject<CachedModelAnimation>
-
isCached
public boolean isCached()- Specified by:
isCachedin interfaceCacheableObject<CachedModelAnimation>
-
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. -
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. -
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 '=='. -
name
Returns the value of thenamerecord component.- Specified by:
namein interfaceModelAnimation- Returns:
- the value of the
namerecord component
-
next
Returns the value of thenextrecord component.- Specified by:
nextin interfaceModelAnimation- Returns:
- the value of the
nextrecord component
-
layer
public int layer()Returns the value of thelayerrecord component.- Specified by:
layerin interfaceModelAnimation- Returns:
- the value of the
layerrecord component
-
frameCount
public int frameCount()Returns the value of theframeCountrecord component.- Specified by:
frameCountin interfaceModelAnimation- Returns:
- the value of the
frameCountrecord component
-
nodeCount
public int nodeCount()Returns the value of thenodeCountrecord component.- Specified by:
nodeCountin interfaceModelAnimation- Returns:
- the value of the
nodeCountrecord component
-
fps
public float fps()Returns the value of thefpsrecord component.- Specified by:
fpsin interfaceModelAnimation- Returns:
- the value of the
fpsrecord component
-
fpsSource
public float fpsSource()Returns the value of thefpsSourcerecord component.- Specified by:
fpsSourcein interfaceModelAnimation- Returns:
- the value of the
fpsSourcerecord component
-
bbox
Returns the value of thebboxrecord component.- Specified by:
bboxin interfaceModelAnimation- Returns:
- the value of the
bboxrecord component
-
checksum
public long checksum()Returns the value of thechecksumrecord component.- Specified by:
checksumin interfaceModelAnimation- Returns:
- the value of the
checksumrecord component
-
sourcePath
Returns the value of thesourcePathrecord component.- Specified by:
sourcePathin interfaceModelAnimation- Returns:
- the value of the
sourcePathrecord component
-
sourceDate
Returns the value of thesourceDaterecord component.- Specified by:
sourceDatein interfaceModelAnimation- Returns:
- the value of the
sourceDaterecord component
-
sourceScript
Returns the value of thesourceScriptrecord component.- Specified by:
sourceScriptin interfaceModelAnimation- Returns:
- the value of the
sourceScriptrecord component
-
samples
Returns the value of thesamplesrecord component.- Specified by:
samplesin interfaceModelAnimation- Returns:
- the value of the
samplesrecord component
-
nodeIndices
public int @NotNull [] nodeIndices()Returns the value of thenodeIndicesrecord component.- Specified by:
nodeIndicesin interfaceModelAnimation- Returns:
- the value of the
nodeIndicesrecord component
-