コード例 #1
0
        private static void onActionRealTimeExchange(WatchAndBreakout st, object customData)
        {
            st.onRealtimeExchange(customData);

            st._timerStopRunning.Update(st.CurrentTime, customData);
            st._timerTryLiquidate.Update(st.CurrentTime, customData);
        }
コード例 #2
0
        private static void onTryLiquidate(WatchAndBreakout st, object customData)
        {
            if (st.isProfitCoverCost())
            {
                st.SwitchRunningState(ERunningState.Stop);
                return;
            }

            st._timerUnconditionLiquidate.Update(st.CurrentTime, customData);
        }
コード例 #3
0
 private static void onStopRunning(WatchAndBreakout st, object customData)
 {
     st.stopRunning();
 }
コード例 #4
0
        private static void onUnconditionLiquidate(WatchAndBreakout st, object customData)
        {
            st.onLiquidatePosition();

            st.SwitchRunningState(ERunningState.Stop);
        }
コード例 #5
0
 private static void onActionWatchDuration(WatchAndBreakout st, object customData)
 {
     st._timerWatching.Update(st.CurrentTime, customData);
 }
コード例 #6
0
 private static void onActionInitFailed(WatchAndBreakout st, object customData)
 {
     st.Print("对冲必须设置2支期货品种!");
 }
コード例 #7
0
 private static void onActionInit(WatchAndBreakout st, object customData)
 {
     st.onCustomInit();
 }