settings

aeq. settings

Source:

[settings description]

Methods

(static) get(sectionName, keyName) → {string|undefined}

Source:

Gets setting from section:key

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Value of saved setting, or undefined if blank

Type
string | undefined

(static) getAsArray(sectionName, keyName) → {Array.<string>|undefined}

Source:

Gets setting and returns as array

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Saved setting as boolean

Type
Array.<string> | undefined

(static) getAsBool(sectionName, keyName) → {boolean|undefined}

Source:

Gets setting and returns as boolean value, or undefined if not boolean

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Saved setting as boolean

Type
boolean | undefined

(static) getAsFloat(sectionName, keyName) → {number|undefined}

Source:

Gets setting and returns as float

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Saved setting as float

Type
number | undefined

(static) getAsInt(sectionName, keyName) → {number|undefined}

Source:

Gets setting and returns as int

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Saved setting as int

Type
number | undefined

(static) have(sectionName, keyName) → {boolean}

Source:

Checks whether setting has been saved / exists in file

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

Returns:

Whether the setting exists

Type
boolean

(static) initSetting(sectionName, keyName, value, overwriteopt) → {string}

Source:

Initializes a setting, setting it if not present

Parameters:
Name Type Attributes Description
sectionName string

Settings section name

keyName string

Settings key name

value string

Settings value to save for section:key

overwrite bool <optional>

true to overwite if present

Returns:

setting value of section:key

Type
string

(static) save(sectionName, keyName, value)

Source:

Saves setting

Parameters:
Name Type Description
sectionName string

Settings section name

keyName string

Settings key name

value string

Settings value to save for section:key

(static) setting(sectionName, keyName, valueopt) → {aeq|string}

Source:

Saves setting if present, else gets setting

Parameters:
Name Type Attributes Description
sectionName string

Settings section name

keyName string

Settings key name

value string <optional>

Settings value to save for section:key

Returns:

aeq or setting value of section:key

Type
aeq | string

(static) unpack(sectionName, keyNames) → {object}

Source:

Checks whether object of key names have saved settings, returns object of saved values of this string

Parameters:
Name Type Description
sectionName string

Settings section name

keyNames object

Object of containing key names

Returns:

Object of fetched settings

Type
object