Record Class AbstractModProvider.DefaultModFileInfo
java.lang.Object
java.lang.Record
net.minecraftforge.fml.loading.moddiscovery.AbstractModProvider.DefaultModFileInfo
- All Implemented Interfaces:
net.minecraftforge.forgespi.language.IConfigurable
,net.minecraftforge.forgespi.language.IModFileInfo
- Enclosing class:
AbstractModProvider
private static record AbstractModProvider.DefaultModFileInfo(net.minecraftforge.forgespi.locating.IModFile mod, String license, net.minecraftforge.forgespi.language.IConfigurable configurable)
extends Record
implements net.minecraftforge.forgespi.language.IModFileInfo, net.minecraftforge.forgespi.language.IConfigurable
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraftforge.forgespi.language.IModFileInfo
net.minecraftforge.forgespi.language.IModFileInfo.LanguageSpec
-
Field Summary
Modifier and TypeFieldDescriptionprivate final net.minecraftforge.forgespi.language.IConfigurable
The field for theconfigurable
record component.private final String
The field for thelicense
record component.private final net.minecraftforge.forgespi.locating.IModFile
The field for themod
record component. -
Constructor Summary
ModifierConstructorDescriptionprivate
DefaultModFileInfo
(net.minecraftforge.forgespi.locating.IModFile mod, String license, net.minecraftforge.forgespi.language.IConfigurable configurable) Creates an instance of aDefaultModFileInfo
record class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraftforge.forgespi.language.IConfigurable
Returns the value of theconfigurable
record component.final boolean
Indicates whether some other object is "equal to" this one.net.minecraftforge.forgespi.language.IConfigurable
<T> Optional
<T> getConfigElement
(String... strings) List
<? extends net.minecraftforge.forgespi.language.IConfigurable> getConfigList
(String... strings) net.minecraftforge.forgespi.locating.IModFile
getFile()
List
<net.minecraftforge.forgespi.language.IModInfo> getMods()
final int
hashCode()
Returns a hash code value for this object.license()
Returns the value of thelicense
record component.net.minecraftforge.forgespi.locating.IModFile
mod()
Returns the value of themod
record component.List
<net.minecraftforge.forgespi.language.IModFileInfo.LanguageSpec> boolean
boolean
toString()
Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraftforge.forgespi.language.IModFileInfo
isClientSideOnly
-
Field Details
-
mod
private final net.minecraftforge.forgespi.locating.IModFile modThe field for themod
record component. -
license
The field for thelicense
record component. -
configurable
private final net.minecraftforge.forgespi.language.IConfigurable configurableThe field for theconfigurable
record component.
-
-
Constructor Details
-
DefaultModFileInfo
private DefaultModFileInfo(net.minecraftforge.forgespi.locating.IModFile mod, String license, net.minecraftforge.forgespi.language.IConfigurable configurable) Creates an instance of aDefaultModFileInfo
record class.- Parameters:
mod
- the value for themod
record componentlicense
- the value for thelicense
record componentconfigurable
- the value for theconfigurable
record component
-
-
Method Details
-
getConfigElement
- Specified by:
getConfigElement
in interfacenet.minecraftforge.forgespi.language.IConfigurable
-
getConfigList
public List<? extends net.minecraftforge.forgespi.language.IConfigurable> getConfigList(String... strings) - Specified by:
getConfigList
in interfacenet.minecraftforge.forgespi.language.IConfigurable
-
getMods
- Specified by:
getMods
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
requiredLanguageLoaders
public List<net.minecraftforge.forgespi.language.IModFileInfo.LanguageSpec> requiredLanguageLoaders()- Specified by:
requiredLanguageLoaders
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
showAsResourcePack
public boolean showAsResourcePack()- Specified by:
showAsResourcePack
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
showAsDataPack
public boolean showAsDataPack()- Specified by:
showAsDataPack
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getFileProperties
- Specified by:
getFileProperties
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getLicense
- Specified by:
getLicense
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getFile
public net.minecraftforge.forgespi.locating.IModFile getFile()- Specified by:
getFile
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getConfig
public net.minecraftforge.forgespi.language.IConfigurable getConfig()- Specified by:
getConfig
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
moduleName
- Specified by:
moduleName
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
versionString
- Specified by:
versionString
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
usesServices
- Specified by:
usesServices
in interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
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)
. -
mod
public net.minecraftforge.forgespi.locating.IModFile mod()Returns the value of themod
record component.- Returns:
- the value of the
mod
record component
-
license
Returns the value of thelicense
record component.- Returns:
- the value of the
license
record component
-
configurable
public net.minecraftforge.forgespi.language.IConfigurable configurable()Returns the value of theconfigurable
record component.- Returns:
- the value of the
configurable
record component
-