HarnessHook
Generated by TypeDoc. Do not edit this page directly.
Abstract Class: HarnessHook<TEvent>
Section titled “Abstract Class: HarnessHook<TEvent>”Defined in: packages/core/src/runtime/types/hooks.ts:12
Type Parameters
Section titled “Type Parameters”| Type Parameter | Default type |
|---|---|
TEvent extends HarnessEvent | HarnessEvent |
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new HarnessHook<TEvent>(): HarnessHook<TEvent>;Returns
Section titled “Returns”HarnessHook<TEvent>
Properties
Section titled “Properties”| Property | Modifier | Type | Defined in |
|---|---|---|---|
eventClass? | readonly | HarnessEventClass<any, TEvent> | packages/core/src/runtime/types/hooks.ts:16 |
label? | public | string | packages/core/src/runtime/types/hooks.ts:15 |
Accessors
Section titled “Accessors”Get Signature
Section titled “Get Signature”get type(): string;Defined in: packages/core/src/runtime/types/hooks.ts:27
Returns
Section titled “Returns”string
Methods
Section titled “Methods”onActive()
Section titled “onActive()”abstract onActive(session, event): void | Promise<void>;Defined in: packages/core/src/runtime/types/hooks.ts:31
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
session | AgentActionSession |
event | TEvent |
Returns
Section titled “Returns”void | Promise<void>
static for<TPayload, TEvent>(eventClass): () => HarnessHook<TEvent>;Defined in: packages/core/src/runtime/types/hooks.ts:18
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
TPayload |
TEvent extends HarnessEvent<TPayload> |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
eventClass | HarnessEventClass<TPayload, TEvent> |
Returns
Section titled “Returns”() => HarnessHook<TEvent>