@eveble/eveble
Hierarchy
↳ Sender
Sender
Publisher
↳ Service
Index
Methods
- ensureHandleability
- getHandleableTypes
- getHandled
- getHandledTypes
- getHandler
- getHandlerOrThrow
- getHandlers
- handle
- handles
- hasHandler
- initialize
- isHandleabe
- overrideHandler
- publish
- registerHandler
- removeHandler
- send
- setHandleableTypes
- subscribeTo
- subscribes
Methods
ensureHandleability
▸ ensureHandleability(messageType
: MessageType‹Message›, handleableTypes
: MessageType‹Message› | MessageType‹Message›[]): boolean
Inherited from Controller.ensureHandleability
Overrides Controller.ensureHandleability
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
handleableTypes | MessageType‹Message› | MessageType‹Message›[] |
Returns: boolean
getHandleableTypes
▸ getHandleableTypes(): MessageType‹Message›[]
Inherited from Controller.getHandleableTypes
Overrides Controller.getHandleableTypes
Returns: MessageType‹Message›[]
getHandled
▸ getHandled(messageType
: MessageType‹Message›): MessageType‹Message›[]
Inherited from Controller.getHandled
Overrides Controller.getHandled
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
Returns: MessageType‹Message›[]
getHandledTypes
▸ getHandledTypes(): MessageType‹Message›[]
Inherited from Controller.getHandledTypes
Overrides Controller.getHandledTypes
Returns: MessageType‹Message›[]
getHandler
▸ getHandler(messageType
: MessageType‹Message›): Handler | Handler[] | undefined
Inherited from Controller.getHandler
Overrides Controller.getHandler
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
Returns: Handler | Handler[] | undefined
getHandlerOrThrow
▸ getHandlerOrThrow(messageType
: MessageType‹Message›): Handler | Handler[]
Inherited from Controller.getHandlerOrThrow
Overrides Controller.getHandlerOrThrow
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
getHandlers
▸ getHandlers(): Map‹MessageType‹Message›, Handler | Handler[]›
Inherited from Controller.getHandlers
Overrides Controller.getHandlers
Returns: Map‹MessageType‹Message›, Handler | Handler[]›
handle
▸ handle(message
: Message, execution?
: Execution): Promise‹any›
Inherited from Controller.handle
Overrides Controller.handle
Parameters:
Name | Type |
---|---|
message | Message |
execution? | Execution |
Returns: Promise‹any›
handles
▸ handles(): Map‹MessageType‹Command›, Handler›
Inherited from Controller.handles
Overrides Controller.handles
Returns: Map‹MessageType‹Command›, Handler›
hasHandler
▸ hasHandler(messageType
: MessageType‹Message›): boolean
Inherited from Controller.hasHandler
Overrides Controller.hasHandler
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
Returns: boolean
initialize
▸ initialize(): void
Inherited from Controller.initialize
Overrides Controller.initialize
Returns: void
isHandleabe
▸ isHandleabe(messageType
: MessageType‹Message›): boolean
Inherited from Controller.isHandleabe
Overrides Controller.isHandleabe
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
Returns: boolean
overrideHandler
▸ overrideHandler(messageType
: MessageType‹Message›, handler
: Handler): void
Inherited from Controller.overrideHandler
Overrides Controller.overrideHandler
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
handler | Handler |
Returns: void
publish
▸ publish(event
: Event): Promise‹void›
Inherited from Publisher.publish
Overrides void
Parameters:
Name | Type |
---|---|
event | Event |
Returns: Promise‹void›
registerHandler
▸ registerHandler(messageType
: MessageType‹Message›, handler
: Handler, shouldOverride?
: boolean): void
Inherited from Controller.registerHandler
Overrides Controller.registerHandler
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
handler | Handler |
shouldOverride? | boolean |
Returns: void
removeHandler
▸ removeHandler(messageType
: MessageType‹Message›): void
Inherited from Controller.removeHandler
Overrides Controller.removeHandler
Parameters:
Name | Type |
---|---|
messageType | MessageType‹Message› |
Returns: void
send
▸ send(command
: Command): Promise‹any›
Overrides void
Parameters:
Name | Type |
---|---|
command | Command |
Returns: Promise‹any›
setHandleableTypes
▸ setHandleableTypes(handleableTypes
: MessageType‹Message› | MessageType‹Message›[]): void
Inherited from Controller.setHandleableTypes
Overrides Controller.setHandleableTypes
Parameters:
Name | Type |
---|---|
handleableTypes | MessageType‹Message› | MessageType‹Message›[] |
Returns: void
subscribeTo
▸ subscribeTo(event
: any, handler
: Handler, shouldOverride?
: boolean): void
Inherited from Publisher.subscribeTo
Overrides void
Parameters:
Name | Type |
---|---|
event | any |
handler | Handler |
shouldOverride? | boolean |
Returns: void
subscribes
▸ subscribes(): Map‹MessageType‹Event›, Handler›
Inherited from Controller.subscribes
Overrides Controller.subscribes
Returns: Map‹MessageType‹Event›, Handler›