You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Andre_601 edited this page Jan 3, 2019
·
1 revision
The Configuration API allows you to generate a config file with all values and comments you define.
This API only allows creation and load of the file.
Configuration notes and value paths are delimited by .-characters.
For example: Value1.Value2 becomes:
Value1:
Value2: //something here
Table of content
FileConfiguration
Used to set a yaml file to the load or write the values too.
Sets values of the FileConfiguration file.
You have to run the #save(); after you set the values, to generate the file.
Example:
config.set("SomeKey", 1);
Parameter:
Type:
String
Name of the key
Object
The value of the key
#save();
Saves the set values from #set(String, Object); to the actual file (Generates it).
#get(String, Object);
Gets the value from the provided key, or sets the default one, if none is set (non-existant).
Run #save(); after this method, to directly save the missing keys.