@eveble/eveble
Hierarchy
Stateful
↳ CommandScheduler
Implemented by
Index
Properties
Methods
- getInterval
- getJob
- getSelectableStates
- getState
- hasState
- initialize
- isInOneOfStates
- isInState
- schedule
- setState
- startScheduling
- stopScheduling
- unschedule
- unscheduleAll
- validateState
Properties
state
• state: State
Overrides void
Methods
getInterval
▸ getInterval(): number
Returns: number
▸ getInterval(): number
Returns: number
getJob
▸ getJob(commandType
: string, assignerId
: string | Stringifiable, assignerType
: string, assignmentId?
: string | Stringifiable): Promise‹ScheduledJob | undefined›
Parameters:
Name | Type |
---|---|
commandType | string |
assignerId | string | Stringifiable |
assignerType | string |
assignmentId? | string | Stringifiable |
Returns: Promise‹ScheduledJob | undefined›
▸ getJob(commandType
: string, assignerId
: string | Stringifiable, assignerType
: string, assignmentId?
: string | Stringifiable): Promise‹ScheduledJob | undefined›
Parameters:
Name | Type |
---|---|
commandType | string |
assignerId | string | Stringifiable |
assignerType | string |
assignmentId? | string | Stringifiable |
Returns: Promise‹ScheduledJob | undefined›
getSelectableStates
▸ getSelectableStates(): Record‹string, State›
Inherited from Stateful.getSelectableStates
Overrides void
Returns: Record‹string, State›
getState
▸ getState(): State
Inherited from Stateful.getState
Overrides void
Returns: State
hasState
▸ hasState(): boolean
Inherited from Stateful.hasState
Overrides void
Returns: boolean
initialize
▸ initialize(): Promise‹void›
Returns: Promise‹void›
▸ initialize(): Promise‹void›
Returns: Promise‹void›
isInOneOfStates
▸ isInOneOfStates(states
: State | State[]): boolean
Inherited from Stateful.isInOneOfStates
Overrides void
Parameters:
Name | Type |
---|---|
states | State | State[] |
Returns: boolean
isInState
▸ isInState(state
: State | State[]): boolean
Inherited from Stateful.isInState
Overrides void
Parameters:
Name | Type |
---|---|
state | State | State[] |
Returns: boolean
schedule
▸ schedule(scheduleCommand
: ScheduleCommand): Promise‹void›
Parameters:
Name | Type |
---|---|
scheduleCommand | ScheduleCommand |
Returns: Promise‹void›
▸ schedule(scheduleCommand
: ScheduleCommand): Promise‹void›
Parameters:
Name | Type |
---|---|
scheduleCommand | ScheduleCommand |
Returns: Promise‹void›
setState
▸ setState(state
: State): void
Inherited from Stateful.setState
Overrides void
Parameters:
Name | Type |
---|---|
state | State |
Returns: void
startScheduling
▸ startScheduling(): Promise‹void›
Returns: Promise‹void›
▸ startScheduling(): Promise‹void›
Returns: Promise‹void›
stopScheduling
▸ stopScheduling(): Promise‹void›
Returns: Promise‹void›
▸ stopScheduling(): Promise‹void›
Returns: Promise‹void›
unschedule
▸ unschedule(unscheduleCommand
: UnscheduleCommand): Promise‹boolean›
Parameters:
Name | Type |
---|---|
unscheduleCommand | UnscheduleCommand |
Returns: Promise‹boolean›
▸ unschedule(unscheduleCommand
: UnscheduleCommand): Promise‹boolean›
Parameters:
Name | Type |
---|---|
unscheduleCommand | UnscheduleCommand |
Returns: Promise‹boolean›
unscheduleAll
▸ unscheduleAll(): Promise‹void›
Returns: Promise‹void›
▸ unscheduleAll(): Promise‹void›
Returns: Promise‹void›
validateState
▸ validateState(stateOrStates
: State | State[], error?
: Error): boolean
Inherited from Stateful.validateState
Overrides void
Parameters:
Name | Type |
---|---|
stateOrStates | State | State[] |
error? | Error |
Returns: boolean