11 lines
359 B
TypeScript
11 lines
359 B
TypeScript
import { EventObject, Subscribable } from './types';
|
|
export interface Actor<TContext = any, TEvent extends EventObject = EventObject> extends Subscribable<TContext> {
|
|
id: string;
|
|
send: (event: TEvent) => any;
|
|
stop?: () => any | undefined;
|
|
toJSON: () => {
|
|
id: string;
|
|
};
|
|
}
|
|
export declare function isActor(item: any): item is Actor;
|