@moonset/executor
Version:
The Moonset Executor
32 lines (31 loc) • 1.02 kB
TypeScript
import * as vi from './visitor';
/**
* The hook function for the plugin to integrate into.
* Here is a sample code to invoke this hook function.
* const fn = PluginHost.instance.hooks[command.op];
* await fn(PluginHost.instance, ...command.args);
*/
export interface MicroCommand {
readonly op: string;
readonly args: any[];
}
/**
* The intermediate representation of Moonset Executor.
*
* It contains an array of CDK commands and SDK commands. CDK commands are
* synchronous and SDK commands are asynchronous. CDK commands are executed and
* deployed before SDK commands execute.
*/
export interface IR {
readonly cdk: MicroCommand[];
readonly sdk: MicroCommand[];
}
export declare class RunVisitor extends vi.SimpleVisitor<IR> {
platform: string;
settings: any;
visitJob(node: vi.JobNode, m: IR): void;
private prepareOutput;
visitInput(node: vi.InputNode, m: IR): void;
visitOutput(node: vi.OutputNode, m: IR): void;
visitTask(node: vi.TaskNode, m: IR): void;
}