export interface Open { o: number; } export interface Close { c: number; } export interface High { h: number; } export interface Low { l: number; } export interface Volume { v: number; } export declare type Bar = Open & Close & High & Low & Volume; export declare type JSONDef> = T & { $type: string; }; export interface Serializable { toJSON(): JSONDef; toString(): string; } interface Constructor { new (): T; from: (props: P) => T; minBars: (props: P) => number; } export declare abstract class Indicator implements Serializable { abstract next(v: number): V | null; abstract nextBar(v: High | Low | Open | Close): VB | null; abstract reset(): void; abstract toJSON(): JSONDef; abstract toString(): string; static init, P, V = number>(this: Constructor, props: P, values: number[]): [C, V | null]; static initBar, P, V = number, VB = V>(this: Constructor, props: P, bars: Bar[]): [C, VB | null]; } export interface SerializableStatic { readonly key: string; display(props: T, value?: string, value2?: string): string; from(props: T): Serializable; } export interface StaticIndicator { new (...args: any[]): Indicator; minBars(props: T): number; init(props: T, bars: number[]): [Indicator, V]; initBar(props: T, bars: Bar[]): [Indicator, VB]; } export {};