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
FieldsModifier and TypeFieldDescriptionprivate final net.minecraftforge.forgespi.language.IConfigurableThe field for theconfigurablerecord component.private final StringThe field for thelicenserecord component.private final net.minecraftforge.forgespi.locating.IModFileThe field for themodrecord component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateDefaultModFileInfo(net.minecraftforge.forgespi.locating.IModFile mod, String license, net.minecraftforge.forgespi.language.IConfigurable configurable) Creates an instance of aDefaultModFileInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraftforge.forgespi.language.IConfigurableReturns the value of theconfigurablerecord component.final booleanIndicates 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.IModFilegetFile()List<net.minecraftforge.forgespi.language.IModInfo>getMods()final inthashCode()Returns a hash code value for this object.license()Returns the value of thelicenserecord component.net.minecraftforge.forgespi.locating.IModFilemod()Returns the value of themodrecord component.List<net.minecraftforge.forgespi.language.IModFileInfo.LanguageSpec>booleanbooleantoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraftforge.forgespi.language.IModFileInfo
isClientSideOnly
-
Field Details
-
mod
private final net.minecraftforge.forgespi.locating.IModFile modThe field for themodrecord component. -
license
The field for thelicenserecord component. -
configurable
private final net.minecraftforge.forgespi.language.IConfigurable configurableThe field for theconfigurablerecord component.
-
-
Constructor Details
-
DefaultModFileInfo
private DefaultModFileInfo(net.minecraftforge.forgespi.locating.IModFile mod, String license, net.minecraftforge.forgespi.language.IConfigurable configurable) Creates an instance of aDefaultModFileInforecord class.- Parameters:
mod- the value for themodrecord componentlicense- the value for thelicenserecord componentconfigurable- the value for theconfigurablerecord component
-
-
Method Details
-
getConfigElement
- Specified by:
getConfigElementin interfacenet.minecraftforge.forgespi.language.IConfigurable
-
getConfigList
public List<? extends net.minecraftforge.forgespi.language.IConfigurable> getConfigList(String... strings) - Specified by:
getConfigListin interfacenet.minecraftforge.forgespi.language.IConfigurable
-
getMods
- Specified by:
getModsin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
requiredLanguageLoaders
public List<net.minecraftforge.forgespi.language.IModFileInfo.LanguageSpec> requiredLanguageLoaders()- Specified by:
requiredLanguageLoadersin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
showAsResourcePack
public boolean showAsResourcePack()- Specified by:
showAsResourcePackin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
showAsDataPack
public boolean showAsDataPack()- Specified by:
showAsDataPackin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getFileProperties
- Specified by:
getFilePropertiesin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getLicense
- Specified by:
getLicensein interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getFile
public net.minecraftforge.forgespi.locating.IModFile getFile()- Specified by:
getFilein interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
getConfig
public net.minecraftforge.forgespi.language.IConfigurable getConfig()- Specified by:
getConfigin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
moduleName
- Specified by:
moduleNamein interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
versionString
- Specified by:
versionStringin interfacenet.minecraftforge.forgespi.language.IModFileInfo
-
usesServices
- Specified by:
usesServicesin 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 themodrecord component.- Returns:
- the value of the
modrecord component
-
license
Returns the value of thelicenserecord component.- Returns:
- the value of the
licenserecord component
-
configurable
public net.minecraftforge.forgespi.language.IConfigurable configurable()Returns the value of theconfigurablerecord component.- Returns:
- the value of the
configurablerecord component
-