IConfigurable class
An interface to set configuration parameters to an object.
It can be added to any existing class by implementing a single configure()
method.
If you need to emphasis the fact that configure()
method can be called multiple times
to change object configuration in runtime, use IReconfigurable interface instead.
See ConfigParams
Example
class MyClass implements IConfigurable {
var _myParam = 'default value';
void configure(ConfigParams config) {
_myParam = config.getAsStringWithDefault('options.param', myParam);
...
}
}
- Implementers
Constructors
Properties
- hashCode → int
-
The hash code for this object. [...]
read-only, inherited
- runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited
Methods
-
configure(
ConfigParams config) → void - Configures component by passing configuration parameters. [...]
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed. [...]
inherited
-
toString(
) → String -
Returns a string representation of this object.
inherited
Operators
-
operator ==(
dynamic other) → bool -
The equality operator. [...]
inherited