Package net.minecraftforge.common
Class ForgeConfigSpec.ConfigValue<T>
java.lang.Object
net.minecraftforge.common.ForgeConfigSpec.ConfigValue<T>
- All Implemented Interfaces:
- Supplier<T>
- Direct Known Subclasses:
- ForgeConfigSpec.BooleanValue,- ForgeConfigSpec.DoubleValue,- ForgeConfigSpec.EnumValue,- ForgeConfigSpec.IntValue,- ForgeConfigSpec.LongValue
- Enclosing class:
- ForgeConfigSpec
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate Tprivate final ForgeConfigSpec.Builderprivate ForgeConfigSpecprivate static boolean
- 
Constructor SummaryConstructorsConstructorDescriptionConfigValue(ForgeConfigSpec.Builder parent, List<String> path, Supplier<T> defaultSupplier) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidget()Returns the actual value for the configuration setting, throwing if the config has not yet been loaded.Returns the default value for the configuration setting.getPath()protected TgetRaw(com.electronwill.nightconfig.core.Config config, List<String> path, Supplier<T> defaultSupplier) next()voidsave()void
- 
Field Details- 
USE_CACHESprivate static boolean USE_CACHES
- 
parent
- 
path
- 
defaultSupplier
- 
cachedValue
- 
spec
 
- 
- 
Constructor Details- 
ConfigValueConfigValue(ForgeConfigSpec.Builder parent, List<String> path, Supplier<T> defaultSupplier) 
 
- 
- 
Method Details- 
getPath
- 
getReturns the actual value for the configuration setting, throwing if the config has not yet been loaded.- Specified by:
- getin interface- Supplier<T>
- Returns:
- the actual value for the setting
- Throws:
- NullPointerException- if the- config specobject that will contain this has not yet been built
- IllegalStateException- if the associated config has not yet been loaded
 
- 
getRaw
- 
getDefaultReturns the default value for the configuration setting.- Returns:
- the default value for the configuration setting
 
- 
next
- 
savepublic void save()
- 
set
- 
clearCachepublic void clearCache()
 
-