Record Class PrefabEntry
java.lang.Object
java.lang.Record
com.hypixel.hytale.server.core.prefab.PrefabEntry
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPrefabEntry(Path path, Path relativePath, AssetPack pack) PrefabEntry(Path path, Path relativePath, AssetPack pack, String displayName) Creates an instance of aPrefabEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionprivate static StringbuildDisplayName(Path relativePath, AssetPack pack) Returns the value of thedisplayNamerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanbooleanpack()Returns the value of thepackrecord component.path()Returns the value of thepathrecord component.Returns the value of therelativePathrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
path
The field for thepathrecord component. -
relativePath
The field for therelativePathrecord component. -
pack
The field for thepackrecord component. -
displayName
The field for thedisplayNamerecord component.
-
-
Constructor Details
-
PrefabEntry
-
PrefabEntry
public PrefabEntry(@Nonnull Path path, @Nonnull Path relativePath, @Nullable AssetPack pack, @Nonnull String displayName) Creates an instance of aPrefabEntryrecord class.- Parameters:
path- the value for thepathrecord componentrelativePath- the value for therelativePathrecord componentpack- the value for thepackrecord componentdisplayName- the value for thedisplayNamerecord component
-
-
Method Details
-
isFromBasePack
public boolean isFromBasePack() -
isFromAssetPack
public boolean isFromAssetPack() -
getPackName
-
getFileName
-
getDisplayNameWithPack
-
buildDisplayName
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
path
Returns the value of thepathrecord component.- Returns:
- the value of the
pathrecord component
-
relativePath
Returns the value of therelativePathrecord component.- Returns:
- the value of the
relativePathrecord component
-
pack
Returns the value of thepackrecord component.- Returns:
- the value of the
packrecord component
-
displayName
Returns the value of thedisplayNamerecord component.- Returns:
- the value of the
displayNamerecord component
-