Package dev.gothickit.zenkit.mdm
Record Class CachedModelMesh
java.lang.Object
java.lang.Record
dev.gothickit.zenkit.mdm.CachedModelMesh
- All Implemented Interfaces:
CacheableObject<CachedModelMesh>,ModelMesh
public record CachedModelMesh(@NotNull List<@NotNull SoftSkinMesh> meshes, @NotNull Map<@NotNull String,@NotNull MultiResolutionMesh> attachments, long checksum)
extends Record
implements ModelMesh
-
Constructor Summary
ConstructorsConstructorDescriptionCachedModelMesh(@NotNull List<@NotNull SoftSkinMesh> meshes, @NotNull Map<@NotNull String, @NotNull MultiResolutionMesh> attachments, long checksum) Creates an instance of aCachedModelMeshrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable MultiResolutionMeshattachment(String name) long@NotNull Map<@NotNull String,@NotNull MultiResolutionMesh> Returns the value of theattachmentsrecord component.@NotNull CachedModelMeshcache()longchecksum()Returns the value of thechecksumrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanisCached()@Nullable SoftSkinMeshmesh(long i) long@NotNull List<@NotNull SoftSkinMesh>meshes()Returns the value of themeshesrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CachedModelMesh
public CachedModelMesh(@NotNull @NotNull List<@NotNull SoftSkinMesh> meshes, @NotNull @NotNull Map<@NotNull String, @NotNull MultiResolutionMesh> attachments, long checksum) Creates an instance of aCachedModelMeshrecord class.- Parameters:
meshes- the value for themeshesrecord componentattachments- the value for theattachmentsrecord componentchecksum- the value for thechecksumrecord component
-
-
Method Details
-
meshCount
public long meshCount() -
mesh
-
attachmentCount
public long attachmentCount()- Specified by:
attachmentCountin interfaceModelMesh
-
attachment
- Specified by:
attachmentin interfaceModelMesh
-
cache
- Specified by:
cachein interfaceCacheableObject<CachedModelMesh>
-
isCached
public boolean isCached()- Specified by:
isCachedin interfaceCacheableObject<CachedModelMesh>
-
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 '=='. -
meshes
Returns the value of themeshesrecord component. -
attachments
Returns the value of theattachmentsrecord component.- Specified by:
attachmentsin interfaceModelMesh- Returns:
- the value of the
attachmentsrecord component
-
checksum
public long checksum()Returns the value of thechecksumrecord component.
-