Class YAMLConfig
java.lang.Object
net.vitacraft.serverlibraries.api.config.YAMLConfig
- All Implemented Interfaces:
Config
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Get a boolean value from the configurationdouble
Get a double value from the configurationint
Get an integer value from the configurationlong
Get a long value from the configurationgetName()
Get the name of the configuration fileGet a string value from the configurationgetStringList
(String key) Get a list of strings from the configurationvoid
Set a boolean value in the configurationvoid
Set a double value in the configurationvoid
Set an integer value in the configurationvoid
Set a long value in the configurationvoid
Set a string value in the configuration
-
Constructor Details
-
YAMLConfig
Create a new YAMLConfig instance- Parameters:
file
- the file to load the configuration from
-
-
Method Details
-
getName
Get the name of the configuration file -
getString
Get a string value from the configuration -
getInt
Get an integer value from the configuration -
getStringList
Get a list of strings from the configuration- Specified by:
getStringList
in interfaceConfig
- Parameters:
key
- the key to get the value from- Returns:
- the list of strings
-
getLong
Get a long value from the configuration -
getDouble
Get a double value from the configuration -
getBool
Get a boolean value from the configuration -
setString
Set a string value in the configuration -
setBool
Set a boolean value in the configuration -
setInt
Set an integer value in the configuration -
setLong
Set a long value in the configuration -
setDouble
Set a double value in the configuration
-