SettingsService class Places
Used to store persistent settings in a key-value pair
Constructors
- SettingsService.new({String? path})
-
Creates or opens a SettingsService at the given path
If no path is given, a default path will be used
factory
- SettingsService.init(int id)
Properties
- group → String
-
Get the name of the current group
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- path → String
-
Get the path where settings written using this SettingsService object are stored.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
beginGroup(
String groupName) → void - Start a group with the specified name
-
clear(
) → void - Remove all settings
-
endGroup(
) → void - End the current group
-
flush(
) → void - Write any unsaved changes to permanent storage.
-
getBool(
String key, {bool defaultValue = false}) → bool - Get a value for the given key
-
getDouble(
String key, {double defaultValue = 0.0}) → double - Get a value for the given key
-
getInt(
String key, {int defaultValue = 0}) → int - Get a value for the given key
-
getLargeInt(
String key, {int defaultValue = 0}) → int - Get a value for the given key
-
getString(
String key, {String defaultValue = ''}) → String - Get a value for the given key
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
registerAutoReleaseObject(
int pointerId) → void -
Registers an object for auto release.
inherited
-
remove(
String key) → int - Remove the specified setting key
-
setBool(
String key, bool value) → void - Set a value for the given key
-
setDouble(
String key, double value) → void - Set a value for the given key
-
setInt(
String key, int value) → void - Set a value for the given key
-
setLargeInt(
String key, int value) → void - Set a value for the given key
-
setString(
String key, String value) → void - Set a value for the given key
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited