Class SettingsFile
Settings object with file information
class SettingsFile
Constructors
Name | Description |
---|---|
this
(filename)
|
Create settings file object; if filename is provided, attempts to load settings from file |
Fields
Type | Name | Description |
---|---|---|
string |
_filename
|
|
std |
_lastModificationTime
|
|
bool |
_loaded
|
|
_setting
|
Properties
Type | Name | Description |
---|---|---|
applySettings [set]
|
||
copySettings [get]
|
||
string |
filename [get, set]
|
Filename |
bool |
loaded [get]
|
|
setting [get]
|
Methods
Name | Description |
---|---|
afterLoad
()
|
Override to do something after loading - e.g. set defaults |
afterSave
()
|
Override to do something after saving |
load
(filename)
|
Load settings from file |
merge
(json)
|
|
replaceSetting
(s)
|
Replace setting object |
save
(filename, pretty)
|
Save settings to file |
updateDefaults
()
|
Override to add default values if missing |
updateModificationTime
()
|
Static methods
Name | Description |
---|---|
limitInt
(value, minvalue, maxvalue)
|
|
limitString
(value, values)
|