Members
adapters :Array.<Object>
- Array.<Object>
connections :Array.<Object>
- Array.<Object>
features :Array.<Object>
- Array.<Object>
getAdapter
Get adapter by name. It returns the first adapter named after "{name}"
Also support NsPath format for those who load the same named adapter but from different provider/plugin.
getAllPropertyKeys
Get all allowed property keys
getConnection
Get connection by name. It returns the first connection named after "{name}"
getFeature
Get feature by name. It returns the first adapter named after "{name}"
Also support NsPath format for those who load the same named adapter but from different provider/plugin.
getModel
Get model by name
getModelsByConnection
Get all models that bound to connection name
getPropertyKeysByType
Get allowed property keys by field type
models :Array.<Object>
- Array.<Object>
(static, constant) aggregateTypes :Array.<string>
- Array.<string>
- Default Value
- ['count', 'avg', 'min', 'max', 'sum']
(static, constant) histogramTypes :Array.<string>
- Array.<string>
- Default Value
- ['daily', 'monthly', 'annually']
(static, constant) idTypes :Array.<string>
- Array.<string>
- Default Value
- ['string', 'integer', 'smallint']
(static, constant) indexTypes :Array.<string>
- Array.<string>
- Default Value
- ['index', 'unique', 'primary', 'fulltext']
(static, constant) propertyType :TPropertyType
- TPropertyType
Methods
(async) init()
Initialize plugin and performing the following tasks:
- Collecting all adapters
- Collecting all connections
- Collecting all features
- Collecting all models
(async) start(connsopt, noRebuildopt)
Start plugin
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
conns | string | | <optional> | all | Which connections should be run on start |
noRebuild | boolean | <optional> | true | Set |
(static) sanitizeDate(value, optionsopt) → {string|Date}
Sanitize value as a date/time value. Parse/format string using dayjs format
| Name | Type | Attributes | Default | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
value | number | | Value to sanitize | ||||||||||||||||||||||
options | Object | <optional> | {} | Options object Properties
|
- Type:
- string |
Date