Package de.smoofy.core.api.config
Schnittstelle IConfig
public interface IConfig
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibungaddIfNotExists
(String key, Object value) Adds a value to the config if it does not exist<T> T
Gets a object from the configboolean
Checks if the config has a keyload()
Loads the configsave()
Saves the configSets a value in the configtoString()
Converts the config to a string
-
Methodendetails
-
get
Gets a object from the config- Parameter:
key
- the keyclazz
- the class- Gibt zurück:
- the object
-
addIfNotExists
Adds a value to the config if it does not exist- Parameter:
key
- the keyvalue
- the value- Gibt zurück:
- the config
-
set
Sets a value in the config- Parameter:
key
- the keyvalue
- the value- Gibt zurück:
- the config
-
load
IConfig load()Loads the config- Gibt zurück:
- the config
-
has
Checks if the config has a key- Parameter:
key
- the key- Gibt zurück:
- true if the config has the key, false otherwise
-
save
IConfig save()Saves the config- Gibt zurück:
- the config
-
toString
String toString()Converts the config to a string
-