Datasource
The datasource class encapsulates the access to data objects.
import { Datasource } from "@schukai/monster/source/data/datasource.mjs";Exported
DatasourceDerived from
BaseOptions
The Options listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits Options from these parent classes. If you cannot find a specific Options in this list, we recommend consulting the documentation of the Base.
Properties
The Properties listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits Properties from these parent classes. If you cannot find a specific Properties in this list, we recommend consulting the documentation of the Base.
Methods
The methods listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits methods from these parent classes. If you cannot find a specific method in this list, we recommend consulting the documentation of the Base.
Constructor
constructor()Structural methods
get()- {Object|Array}
getOption(path,defaultValue)path{string}: pathdefaultValue{*}: defaultValue
- {*}
a.b.cset(data)data{object|array}: data
- {Datasource}
setOption(path,value)path{string}: pathvalue{*}: value
- {Datasource}
setOptions(options)options{string|object}: options
- {Datasource}
{Error}the options does not contain a valid json definition
Static methods
[instanceSymbol]()2.1.0- {symbol}
instanceof operator.Other methods
attachObserver(observer)observer{observer}: observer
- {Datasource}
containsObserver(observer)observer{observer}: observer
- {boolean}
detachObserver(observer)observer{observer}: observer
- {Datasource}
read()- {Promise}
{Error}this method must be implemented by derived classes.
write()- {Promise}
{Error}this method must be implemented by derived classes.
Events
This component does not fire any public events. It may fire events that are inherited from its parent classes.