Class: ConfigurationService
Webda Modda
webdashell/configuration
Extends
Service
Implements
RequestFilter
<WebContext
>
Constructors
new ConfigurationService(webda, name, params)
new ConfigurationService(
webda
,name
,params
?):ConfigurationService
Parameters
• webda: Core
<CoreEvents
>
The main instance of Webda
• name: string
The name of the service
• params?: DeepPartial
<ServiceParameters
>
The parameters block define in the configuration file
Returns
Inherited from
Service.constructor
Source
packages/core/lib/services/service.d.ts:168
Properties
_createException
_createException:
string
Inherited from
Service._createException
Source
packages/core/lib/services/service.d.ts:149
_initException
_initException:
any
Inherited from
Service._initException
Source
packages/core/lib/services/service.d.ts:151
_initTime
_initTime:
number
Inherited from
Service._initTime
Source
packages/core/lib/services/service.d.ts:150
_name
protected
_name:string
Service name
Inherited from
Service._name
Source
packages/core/lib/services/service.d.ts:142
_webda
protected
_webda:Core
<CoreEvents
>
Webda Core object
Inherited from
Service._webda
Source
packages/core/lib/services/service.d.ts:138
logger
protected
logger:Logger
Logger with class context
Inherited from
Service.logger
Source
packages/core/lib/services/service.d.ts:155
metrics?
protected
metrics?:any
Get metrics
Inherited from
Service.metrics
Source
packages/core/lib/services/service.d.ts:159
parameters
protected
parameters:ServiceParameters
Hold the parameters for your service
It will be bring from the webda.config.json
Inherited from
Service.parameters
Source
packages/core/lib/services/service.d.ts:148
webdaApplication
webdaApplication:
Application
Source
packages/shell/src/handlers/config.ts:19
captureRejectionSymbol
static
readonly
captureRejectionSymbol: typeofcaptureRejectionSymbol
Inherited from
Service.captureRejectionSymbol
Source
packages/shell/node_modules/@types/node/events.d.ts:328
captureRejections
static
captureRejections:boolean
Sets or gets the default captureRejection value for all emitters.
Inherited from
Service.captureRejections
Source
packages/shell/node_modules/@types/node/events.d.ts:333
defaultMaxListeners
static
defaultMaxListeners:number
Inherited from
Service.defaultMaxListeners
Source
packages/shell/node_modules/@types/node/events.d.ts:334
errorMonitor
static
readonly
errorMonitor: typeoferrorMonitor
This symbol shall be used to install a listener for only monitoring 'error'
events. Listeners installed using this symbol are called before the regular
'error'
listeners are called.
Installing a listener using this symbol does not change the behavior once an
'error'
event is emitted, therefore the process will still crash if no
regular 'error'
listener is installed.
Inherited from
Service.errorMonitor
Source
packages/shell/node_modules/@types/node/events.d.ts:327
Methods
__clean()
__clean():
Promise
<void
>
Clean the service data, can only be used in test mode
Returns
Promise
<void
>
Inherited from
Service.__clean
Abstract
Source
packages/core/lib/services/service.d.ts:319
addListener()
addListener(
eventName
,listener
):this
Alias for emitter.on(eventName, listener)
.
Parameters
• eventName: string
| symbol
• listener: (...args
) => void
Returns
this
Inherited from
Service.addListener
Since
v0.1.26
Source
packages/shell/node_modules/@types/node/events.d.ts:354
addRoute()
protected
addRoute(url
,methods
,executer
,openapi
?,override
?):void
Add a route dynamicaly
Parameters
• url: string
of the route can contains dynamic part like {uuid}
• methods: HttpMethodType
[]
• executer: Function
Method to execute for this route
• openapi?: OpenAPIWebdaDefinition
• override?: boolean
Returns
void
Inherited from
Service.addRoute
Source
packages/core/lib/services/service.d.ts:242
authorizeClientEvent()
authorizeClientEvent(
_event
,_context
):boolean
Authorize a public event subscription
Parameters
• _event: string
• _context: OperationContext
<any
, any
>
Returns
boolean
Inherited from
Service.authorizeClientEvent
Source
packages/core/lib/services/service.d.ts:220
checkRequest()
checkRequest(
context
):Promise
<boolean
>
Parameters
• context: WebContext
<any
, any
>
Returns
Promise
<boolean
>
Implementation of
RequestFilter.checkRequest
Source
packages/shell/src/handlers/config.ts:21
computeParameters()
computeParameters():
void
Used to compute or derivate input parameter to attribute
Returns
void
Inherited from
Service.computeParameters
Source
packages/core/lib/services/service.d.ts:176
crudConfiguration()
crudConfiguration(
ctx
):Promise
<void
>
Parameters
• ctx: WebContext
<any
, any
>
Returns
Promise
<void
>
Source
packages/shell/src/handlers/config.ts:47
emit()
emit<
Key
>(event
,data
):boolean
Override to allow capturing long listeners
Type parameters
• Key extends string
| number
Parameters
• event: symbol
| Key