@ipp/cli
Version:
An image build orchestrator for the modern web
34 lines (33 loc) • 899 B
TypeScript
/**
* Image Processing Pipeline - Copyright (c) Marcus Cemes
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
import { Observable } from "rxjs";
export declare enum Status {
READY = 0,
PROCESSING = 1,
COMPLETE = 2,
ERROR = 3,
INTERRUPT = 4
}
export interface State {
status: Status;
concurrency: number;
clean: boolean;
manifest: boolean;
images: {
found: number;
completed: number;
failed: number;
};
}
export declare type StateObservable = Observable<State>;
export interface StateContext {
observable: StateObservable;
getValue: () => State;
update: (fn: (state: State) => void) => void;
complete: () => State;
}
export declare function createStateContext(concurrency: number, manifest: boolean, clean: boolean): StateContext;