transgate
Version:
Agent-based task flow framework
18 lines (17 loc) • 495 B
TypeScript
import { OutGate, GateItem } from './type';
/**
* Stdout Gate for Output
*/
export declare class StdoutGate<T extends GateItem> implements OutGate<T> {
/**
* @param {object} item - sending item
* @return {Promise} - a promise that resolves when the item has been sended
*/
send(item: T): Promise<void>;
/**
* Convert item to string
* @param {object} item - sended item
* @return {string} written to stdout
*/
_stringify(item: T): string;
}