import { EntityMetadata } from '../Redux/EntityMetadata'; import { SerializableCommand } from './SerializableCommand'; import { Command, CommandConstructor } from 'ts-eventsourcing/CommandHandling/Command'; import { SerializableQuery } from '../QueryHandling/SerializableQuery'; export interface CommandAction { type: string; metadata: EntityMetadata & Metadata & { response?: any; }; command: T; } export interface CommandResponseAction extends CommandAction { response: Response; } export declare function commandActionTypeFactory(type: string): (entity: string, command: object | CommandConstructor) => string; export declare function isCommandActionOfType(action: any, type: (entity: string, command: CommandConstructor | Command) => string): action is CommandAction; export declare function isCommandAction(action: any): action is CommandAction; export declare function asCommandAction(action: any, command: CommandConstructor): CommandAction;