regress:regression: fix a run error

Fix a run error caused by wrong reference to showStat()
while runStat is not enabled by strategy.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
strategy:futures: fix a bug to close multiple positions

Fix a bug to close multiple positions in closeMultPostion().

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
strategy:futures: fix a bug to calculate profit

Fix a bug to calculate profit while minPos is bigger than 1.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
strategy/regress: replace 'maxPos' with 'maxAddPos'

Replace maxPos with maxAddPos because maxPos actually works
as the max positions allowed to add for a bussiness.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
 strategy:turtle: use ATR as minPosIntv

1) Add checkAtr() and getAtr() for TurtData.
2) Update regression framework to be able to use ATR as
   minPosIntv.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
regress: add tick subsystem

Tick simulates a ticks source to Trading system. When
tick varies (typically increase), it means a new trade
cycle comes, Trading system needs to make decision if
need to do any operation.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
dataMgr:whImporter: add new time format support

Add support to new time format 'mm/dd/yyyy' imported to
database. We just support 'yyyy-mm-dd' format in the past.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
regress: add emulate subsystem

Emulation is capable of running a set of regressions
parallelly simulating real Future trading.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
regress:emulate: add log management support

1) Add log management to support storing logs to files.
2) Add show run statistics at end of emulation.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>
strategy:futures/turtle: add emulation support

1) Make strategy could be run in a thread receiving
   ticks from main thread and only run one tick for
   one time.
2) Add support to store logs to files.

Signed-off-by: Zhengwang Ruan <ruan.zhengwang@gmail.com>