Package arc
Class Settings
java.lang.Object
arc.util.JsonSettings
arc.Settings
- All Implemented Interfaces:
Autosaver.Saveable
- Direct Known Subclasses:
MockSettings
-
Field Summary
FieldsFields inherited from class arc.util.JsonSettings
autosaved, backuped, backupFile, builder, compressed, defaults, errorHandler, file, json, loaded, modified, plainJson, reader, simple, values -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidautosave()Deprecated.This is useless.file()Deprecated.Not used.Deprecated.Just for compatibility.Returns the directory where all settings and data is placed.Deprecated.Just for compatibility.intkeySize()Deprecated.Just for compatibility.voidDeprecated.Just for compatibility.voidDeprecated.UseJsonSettings.save()instead.voidDeprecated.Just for compatibility.voidsetAppName(String name) voidsetAutosave(boolean autosave) Deprecated.UsesetAutosaved(boolean)instead.voidsetAutosaved(boolean autosave) voidsetDataDirectory(Fi file) Sets the settings file where everything is written to.Methods inherited from class arc.util.JsonSettings
addSerializer, backupExists, clear, defaults, exists, forceSave, get, get, get, get, get, getBool, getBool, getBoolOnce, getBoolOnce, getDefault, getDouble, getDouble, getFloat, getFloat, getInt, getInt, getJson, getLong, getLong, getOrPut, getOrPut, getOrPut, getOrPut, getString, getString, has, isAutosaved, isBackuped, isCompressed, isKnownType, isPlainJson, keys, load, loaded, loadValues, modified, name, put, put, put, putAll, remove, save, saveValues, setBackuped, setCompressed, setDefault, setErrorHandler, size
-
Field Details
-
dataDirectory
-
appName
-
-
Constructor Details
-
Settings
public Settings()
-
-
Method Details
-
getAppName
-
setAppName
-
setAutosave
Deprecated.UsesetAutosaved(boolean)instead.Set whether the data should autosave immediately upon changing a value. Default value: true. -
setAutosaved
public void setAutosaved(boolean autosave) - Overrides:
setAutosavedin classJsonSettings
-
manualSave
Deprecated.UseJsonSettings.save()instead.Manually save, if the settings have been loaded at some point. -
autosave
Deprecated.This is useless.Saves if any modifications were done. -
loadValues
Deprecated.Just for compatibility.Loads a settings file intoJsonSettings.valuesusing the specified appName. -
saveValues
Deprecated.Just for compatibility. Saves all entries fromJsonSettings.valuesinto the correct location. -
getSettingsFile
Deprecated.Just for compatibility. Usefile()instead. Returns the file used for writing settings to. Not available on all platforms! -
getBackupFolder
Deprecated.Not used. -
getBackupSettingsFile
Deprecated.Just for compatibility. UsebackupFile()instead. -
file
- Overrides:
filein classJsonSettings- Returns:
- the file used for writing settings to.
-
backupFile
- Overrides:
backupFilein classJsonSettings- Returns:
- the file used for recovering settings.
-
getDataDirectory
Returns the directory where all settings and data is placed. -
setDataDirectory
Sets the settings file where everything is written to. -
keySize
Deprecated.Just for compatibility. UseJsonSettings.size()instead.
-