import { VCommission, VFormatType, VScale, VStrategy, VDirection, VOca } from "./enum";
export type CloseEntriesRuleType = 'FIFO' | 'ANY';
export interface IStrategy {
    title?: string;
    shorttitle?: string;
    overlay?: boolean;
    format?: VFormatType;
    precision?: number;
    scale?: VScale;
    pyramiding?: number;
    calc_on_order_fills?: boolean;
    calc_on_every_tick?: boolean;
    max_bars_back?: number;
    backtest_fill_limits_assumption?: number;
    default_qty_type?: VStrategy;
    default_qty_value?: number;
    initial_capital: number;
    currency?: string;
    slippage?: number;
    commission_type?: VCommission;
    commission_value?: number;
    process_orders_on_close?: boolean;
    close_entries_rule?: CloseEntriesRuleType;
    margin_long?: number;
    margin_short?: number;
    explicit_plot_zorder?: boolean;
    max_lines_count?: number;
    max_labels_count?: number;
    max_boxes_count?: number;
    calc_bars_count?: number;
    risk_free_rate?: number;
    use_bar_magnifier?: boolean;
    fill_orders_on_standard_ohlc?: boolean;
    max_polylines_count?: number;
    scriptType?: string;
    direction_short_long?: boolean;
}
export type PlaceOrderType = 'order' | 'entry' | 'exit' | 'close' | 'close_all' | 'close_all_short' | 'close_all_long';
export interface IOrder extends IOrderArgs {
    isMarketPrice?: boolean;
    out_id?: string;
    in_index?: number;
    out_index?: number;
    in_price: number;
    out_price?: number;
    in_time?: number;
    out_time?: number;
    out_qty?: number;
    out_comment?: string;
    total_profit?: number;
    max_profit?: number;
    trading_loss?: number;
    place_order_type?: PlaceOrderType;
    position_close_type?: PlaceOrderType;
    isDeal?: boolean;
    exitIds?: string[];
    active_price?: number;
    trail_stop_price?: number;
    hasOrder?: boolean;
    isMarketPriceLimit?: boolean;
    isMarketPriceStop?: boolean;
    isCancel?: boolean;
    close_qty?: number;
    profit_percent?: number;
    max_profit_percent?: number;
    trading_loss_percent?: number;
    commission?: number;
    original_qty?: number;
    in_low?: number;
    in_high?: number;
    out_low?: number;
    out_high?: number;
    isTiggerClose?: boolean;
    entry_time?: number;
}
export interface IOrderArgs {
    id: string;
    direction: VDirection;
    from_entry?: string;
    qty?: number;
    limit?: number;
    loss?: number;
    stop?: number;
    oca_name?: string;
    oca_type?: VOca;
    comment?: string;
    alert_message?: string;
    disable_alert?: false;
    qty_percent?: number;
    immediately?: boolean;
    trail_price?: number;
    trail_points?: number;
    trail_offset?: number;
    profit?: number;
    comment_profit?: string;
    comment_loss?: string;
    comment_trailing?: string;
    last_commission?: number;
}
export interface IExitOrder extends IOrderArgs {
    order: IOrder;
    active_price?: number;
    trail_stop_price?: number;
    directionNum: number;
    isClose?: boolean;
}
export interface IColorArgs {
    x?: any;
    color?: string;
    value?: number;
    bottom_value?: number;
    top_value?: number;
    bottom_color?: string;
    top_color?: string;
    transp?: number;
    red?: number;
    green?: number;
    blue?: number;
}
