Record Class ClientExtensionInfo.Block
java.lang.Object
java.lang.Record
org.moddingx.libx.registration.util.ClientExtensionInfo.Block
- Enclosing class:
ClientExtensionInfo
public static record ClientExtensionInfo.Block(Supplier<net.neoforged.neoforge.client.extensions.common.IClientBlockExtensions> extensions)
extends Record
Wraps some
client block extensions
. Using the LibX registration system, an
instance of this class can be registered on the client using the same id as the associated
Block
to set up the client block extensions
.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.Supplier
<net.neoforged.neoforge.client.extensions.common.IClientBlockExtensions> Returns the value of theextensions
record component.final int
hashCode()
Returns a hash code value for this object.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
Block
public Block(net.neoforged.neoforge.client.extensions.common.IClientBlockExtensions extensions) -
Block
public Block(Supplier<net.neoforged.neoforge.client.extensions.common.IClientBlockExtensions> extensions) Creates an instance of aBlock
record class.- Parameters:
extensions
- the value for theextensions
record component
-
-
Method Details
-
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)
. -
extensions
public Supplier<net.neoforged.neoforge.client.extensions.common.IClientBlockExtensions> extensions()Returns the value of theextensions
record component.- Returns:
- the value of the
extensions
record component
-