sync 1.6.2 ctpgateway
This commit is contained in:
parent
e38a69bbcf
commit
b942d33388
@ -1,13 +1,11 @@
|
|||||||
# encoding: UTF-8
|
# encoding: UTF-8
|
||||||
|
|
||||||
import sys
|
|
||||||
import os
|
import os
|
||||||
|
|
||||||
#print u'init {0}'.format(os.path.dirname(__file__))
|
print u'init path:{0}'.format(os.path.dirname(__file__))
|
||||||
from vnpy.trader import vtConstant
|
from vnpy.trader import vtConstant
|
||||||
from ctpGateway import CtpGateway
|
from ctpGateway import CtpGateway
|
||||||
|
|
||||||
|
|
||||||
gatewayClass = CtpGateway
|
gatewayClass = CtpGateway
|
||||||
gatewayName = 'CTP'
|
gatewayName = 'CTP'
|
||||||
gatewayDisplayName = 'CTP'
|
gatewayDisplayName = 'CTP'
|
||||||
|
@ -6,21 +6,18 @@ vn.ctp的gateway接入
|
|||||||
考虑到现阶段大部分CTP中的ExchangeID字段返回的都是空值
|
考虑到现阶段大部分CTP中的ExchangeID字段返回的都是空值
|
||||||
vtSymbol直接使用symbol
|
vtSymbol直接使用symbol
|
||||||
'''
|
'''
|
||||||
|
print 'loading ctpGateway.py'
|
||||||
import os
|
import os
|
||||||
import sys
|
|
||||||
import json
|
import json
|
||||||
from copy import copy
|
|
||||||
from datetime import datetime
|
|
||||||
import logging
|
|
||||||
|
|
||||||
|
# 加载经booster编译转换的SO API库
|
||||||
from vnctpmd import MdApi
|
from vnctpmd import MdApi
|
||||||
from vnctptd import TdApi
|
from vnctptd import TdApi
|
||||||
|
|
||||||
from vnpy.trader.vtConstant import *
|
from vnpy.trader.vtConstant import *
|
||||||
from vnpy.trader.vtGateway import *
|
from vnpy.trader.vtGateway import *
|
||||||
from ctpDataType import *
|
|
||||||
from vnpy.trader.gateway.ctpGateway.language import text
|
from vnpy.trader.gateway.ctpGateway.language import text
|
||||||
|
from vnpy.trader.gateway.ctpGateway.ctpDataType import *
|
||||||
|
|
||||||
# 以下为一些VT类型和CTP类型的映射字典
|
# 以下为一些VT类型和CTP类型的映射字典
|
||||||
# 价格类型映射
|
# 价格类型映射
|
||||||
|
@ -1,10 +1,7 @@
|
|||||||
# encoding: UTF-8
|
# encoding: UTF-8
|
||||||
|
|
||||||
import json
|
|
||||||
import os
|
import os
|
||||||
import traceback
|
print u'load {0}/*'.format(os.path.dirname(__file__))
|
||||||
|
|
||||||
#print u'init {0}'.format(os.path.dirname(__file__))
|
|
||||||
|
|
||||||
# 默认设置
|
# 默认设置
|
||||||
from chinese import text
|
from chinese import text
|
||||||
|
Loading…
Reference in New Issue
Block a user