Record Class ImageResource.PackRoot
java.lang.Object
java.lang.Record
net.neoforged.neoforge.client.gui.modlist.ImageResource.PackRoot
- All Implemented Interfaces:
ImageResource
- Enclosing interface:
ImageResource
@Internal
public static record ImageResource.PackRoot(String packId, String path)
extends Record
implements ImageResource
-
Nested Class Summary
Nested classes/interfaces inherited from interface ImageResource
ImageResource.PackAsset, ImageResource.PackRoot -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.get(ResourceManager resourceManager) Retrieves the image resource contents from the given resource manager.final inthashCode()Returns a hash code value for this object.packId()Returns the value of thepackIdrecord component.path()Returns the value of thepathrecord component.toString()Returns a string representation of this record class.
-
Field Details
-
packId
The field for thepackIdrecord component. -
path
The field for thepathrecord component. -
PATH_SPLITTER
-
-
Constructor Details
-
PackRoot
-
-
Method Details
-
get
Description copied from interface:ImageResourceRetrieves the image resource contents from the given resource manager. If the resource does not exist, this returnsnull.- Specified by:
getin interfaceImageResource- Parameters:
resourceManager- the resource manager, which is expected to contain client-side resource packs- Returns:
- the supplier for the image bytes
-
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 withObjects::equals(Object,Object). -
packId
Returns the value of thepackIdrecord component.- Returns:
- the value of the
packIdrecord component
-
path
Returns the value of thepathrecord component.- Returns:
- the value of the
pathrecord component
-