@hitrading/ctp-node 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +208 -0
- package/README.zh-CN.md +185 -0
- package/binding.gyp +90 -0
- package/dist/client.d.ts +115 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +466 -0
- package/dist/client.js.map +1 -0
- package/dist/codec.d.ts +29 -0
- package/dist/codec.d.ts.map +1 -0
- package/dist/codec.js +131 -0
- package/dist/codec.js.map +1 -0
- package/dist/generated/enums.gen.d.ts +2257 -0
- package/dist/generated/enums.gen.d.ts.map +1 -0
- package/dist/generated/enums.gen.js +2576 -0
- package/dist/generated/enums.gen.js.map +1 -0
- package/dist/generated/structs.gen.d.ts +11041 -0
- package/dist/generated/structs.gen.d.ts.map +1 -0
- package/dist/generated/structs.gen.js +939 -0
- package/dist/generated/structs.gen.js.map +1 -0
- package/dist/generated/trader.gen.d.ts +273 -0
- package/dist/generated/trader.gen.d.ts.map +1 -0
- package/dist/generated/trader.gen.js +653 -0
- package/dist/generated/trader.gen.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -0
- package/dist/market-data.d.ts +66 -0
- package/dist/market-data.d.ts.map +1 -0
- package/dist/market-data.js +105 -0
- package/dist/market-data.js.map +1 -0
- package/dist/native-binding.d.ts +2 -0
- package/dist/native-binding.d.ts.map +1 -0
- package/dist/native-binding.js +22 -0
- package/dist/native-binding.js.map +1 -0
- package/dist/trader.d.ts +234 -0
- package/dist/trader.d.ts.map +1 -0
- package/dist/trader.js +388 -0
- package/dist/trader.js.map +1 -0
- package/package.json +69 -0
- package/prebuilds/linux-x64/@hitrading+ctp-node.node +0 -0
- package/prebuilds/linux-x64/thostmduserapi_se.so +0 -0
- package/prebuilds/linux-x64/thosttraderapi_se.so +0 -0
- package/prebuilds/win32-x64/@hitrading+ctp-node.node +0 -0
- package/prebuilds/win32-x64/thostmduserapi_se.dll +0 -0
- package/prebuilds/win32-x64/thosttraderapi_se.dll +0 -0
- package/src/addon.cc +171 -0
- package/src/client.ts +539 -0
- package/src/codec.ts +160 -0
- package/src/generated/enums.gen.ts +2576 -0
- package/src/generated/layout.gen.cc +5771 -0
- package/src/generated/layout.gen.h +8 -0
- package/src/generated/structids.gen.h +470 -0
- package/src/generated/structs.gen.ts +12437 -0
- package/src/generated/trader.gen.ts +656 -0
- package/src/generated/traderreq.gen.cc +706 -0
- package/src/generated/traderreq.gen.h +127 -0
- package/src/generated/traderspi.gen.cc +636 -0
- package/src/generated/traderspi.gen.h +334 -0
- package/src/index.ts +14 -0
- package/src/market-data.ts +145 -0
- package/src/native/arm.cc +77 -0
- package/src/native/arm.h +71 -0
- package/src/native/channel.cc +175 -0
- package/src/native/channel.h +117 -0
- package/src/native/gbk.cc +54 -0
- package/src/native/gbk.h +17 -0
- package/src/native/mdapi.cc +412 -0
- package/src/native/mdapi.h +14 -0
- package/src/native/mdspi.cc +103 -0
- package/src/native/mdspi.h +81 -0
- package/src/native/risk.cc +461 -0
- package/src/native/risk.h +183 -0
- package/src/native/traderapi.cc +533 -0
- package/src/native/traderapi.h +14 -0
- package/src/native-binding.ts +25 -0
- package/src/trader.ts +522 -0
- package/tradeapi/ThostFtdcMdApi.h +168 -0
- package/tradeapi/ThostFtdcTraderApi.h +914 -0
- package/tradeapi/ThostFtdcUserApiDataType.h +7068 -0
- package/tradeapi/ThostFtdcUserApiStruct.h +12386 -0
- package/tradeapi/error.dtd +9 -0
- package/tradeapi/error.xml +284 -0
- package/tradeapi/linux/thostmduserapi_se.so +0 -0
- package/tradeapi/linux/thosttraderapi_se.so +0 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/Headers/ThostFtdcMdApi.h +168 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/Headers/ThostFtdcUserApiDataType.h +7068 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/Headers/ThostFtdcUserApiStruct.h +12386 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/Resources/Info.plist +46 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/_CodeSignature/CodeResources +149 -0
- package/tradeapi/macos/thostmduserapi_se.framework/Versions/A/thostmduserapi_se +0 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/Headers/ThostFtdcTraderApi.h +914 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/Headers/ThostFtdcUserApiDataType.h +7068 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/Headers/ThostFtdcUserApiStruct.h +12386 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/Resources/Info.plist +46 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/_CodeSignature/CodeResources +149 -0
- package/tradeapi/macos/thosttraderapi_se.framework/Versions/A/thosttraderapi_se +0 -0
- package/tradeapi/windows/thostmduserapi_se.dll +0 -0
- package/tradeapi/windows/thostmduserapi_se.lib +0 -0
- package/tradeapi/windows/thosttraderapi_se.dll +0 -0
- package/tradeapi/windows/thosttraderapi_se.lib +0 -0
|
@@ -0,0 +1,636 @@
|
|
|
1
|
+
/* AUTO-GENERATED. Do not edit. */
|
|
2
|
+
#include "traderspi.gen.h"
|
|
3
|
+
#include "structids.gen.h"
|
|
4
|
+
|
|
5
|
+
namespace ctp {
|
|
6
|
+
|
|
7
|
+
static int eid(CThostFtdcRspInfoField *e) { return e ? e->ErrorID : 0; }
|
|
8
|
+
static const char *emsg(CThostFtdcRspInfoField *e) { return (e && e->ErrorID) ? e->ErrorMsg : ""; }
|
|
9
|
+
|
|
10
|
+
void TraderSpi::OnFrontConnected() {
|
|
11
|
+
ch_->push(ET_FrontConnected, 0, -1, 0, "", -1, nullptr, 0);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
void TraderSpi::OnFrontDisconnected(int arg) {
|
|
15
|
+
ch_->push(ET_FrontDisconnected, 0, -1, 0, "", -2, &arg, sizeof(arg));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
void TraderSpi::OnHeartBeatWarning(int arg) {
|
|
19
|
+
ch_->push(ET_HeartBeatWarning, 0, -1, 0, "", -2, &arg, sizeof(arg));
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
void TraderSpi::OnRspAuthenticate(CThostFtdcRspAuthenticateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
23
|
+
ch_->push(ET_RspAuthenticate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RspAuthenticate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
void TraderSpi::OnRspUserLogin(CThostFtdcRspUserLoginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
27
|
+
if (p && risk_)
|
|
28
|
+
risk_->setSession(p->FrontID, p->SessionID);
|
|
29
|
+
ch_->push(ET_RspUserLogin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RspUserLogin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
void TraderSpi::OnRspUserLogout(CThostFtdcUserLogoutField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
33
|
+
ch_->push(ET_RspUserLogout, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_UserLogout : -1, p, p ? (int)sizeof(*p) : 0);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
void TraderSpi::OnRspUserPasswordUpdate(CThostFtdcUserPasswordUpdateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
37
|
+
ch_->push(ET_RspUserPasswordUpdate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_UserPasswordUpdate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
void TraderSpi::OnRspTradingAccountPasswordUpdate(CThostFtdcTradingAccountPasswordUpdateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
41
|
+
ch_->push(ET_RspTradingAccountPasswordUpdate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TradingAccountPasswordUpdate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
void TraderSpi::OnRspUserAuthMethod(CThostFtdcRspUserAuthMethodField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
45
|
+
ch_->push(ET_RspUserAuthMethod, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RspUserAuthMethod : -1, p, p ? (int)sizeof(*p) : 0);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
void TraderSpi::OnRspGenUserCaptcha(CThostFtdcRspGenUserCaptchaField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
49
|
+
ch_->push(ET_RspGenUserCaptcha, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RspGenUserCaptcha : -1, p, p ? (int)sizeof(*p) : 0);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
void TraderSpi::OnRspGenUserText(CThostFtdcRspGenUserTextField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
53
|
+
ch_->push(ET_RspGenUserText, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RspGenUserText : -1, p, p ? (int)sizeof(*p) : 0);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
void TraderSpi::OnRspOrderInsert(CThostFtdcInputOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
57
|
+
if (p && risk_)
|
|
58
|
+
risk_->releaseReservation(p->OrderRef);
|
|
59
|
+
ch_->push(ET_RspOrderInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
void TraderSpi::OnRspParkedOrderInsert(CThostFtdcParkedOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
63
|
+
ch_->push(ET_RspParkedOrderInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ParkedOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
void TraderSpi::OnRspParkedOrderAction(CThostFtdcParkedOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
67
|
+
ch_->push(ET_RspParkedOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ParkedOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
void TraderSpi::OnRspOrderAction(CThostFtdcInputOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
71
|
+
ch_->push(ET_RspOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
void TraderSpi::OnRspQryMaxOrderVolume(CThostFtdcQryMaxOrderVolumeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
75
|
+
ch_->push(ET_RspQryMaxOrderVolume, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_QryMaxOrderVolume : -1, p, p ? (int)sizeof(*p) : 0);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
void TraderSpi::OnRspSettlementInfoConfirm(CThostFtdcSettlementInfoConfirmField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
79
|
+
ch_->push(ET_RspSettlementInfoConfirm, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SettlementInfoConfirm : -1, p, p ? (int)sizeof(*p) : 0);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
void TraderSpi::OnRspRemoveParkedOrder(CThostFtdcRemoveParkedOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
83
|
+
ch_->push(ET_RspRemoveParkedOrder, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RemoveParkedOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
void TraderSpi::OnRspRemoveParkedOrderAction(CThostFtdcRemoveParkedOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
87
|
+
ch_->push(ET_RspRemoveParkedOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RemoveParkedOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
void TraderSpi::OnRspExecOrderInsert(CThostFtdcInputExecOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
91
|
+
ch_->push(ET_RspExecOrderInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputExecOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
void TraderSpi::OnRspExecOrderAction(CThostFtdcInputExecOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
95
|
+
ch_->push(ET_RspExecOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputExecOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
void TraderSpi::OnRspForQuoteInsert(CThostFtdcInputForQuoteField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
99
|
+
ch_->push(ET_RspForQuoteInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputForQuote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
void TraderSpi::OnRspQuoteInsert(CThostFtdcInputQuoteField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
103
|
+
ch_->push(ET_RspQuoteInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputQuote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
void TraderSpi::OnRspQuoteAction(CThostFtdcInputQuoteActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
107
|
+
ch_->push(ET_RspQuoteAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputQuoteAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
void TraderSpi::OnRspBatchOrderAction(CThostFtdcInputBatchOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
111
|
+
ch_->push(ET_RspBatchOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputBatchOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
void TraderSpi::OnRspOptionSelfCloseInsert(CThostFtdcInputOptionSelfCloseField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
115
|
+
ch_->push(ET_RspOptionSelfCloseInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputOptionSelfClose : -1, p, p ? (int)sizeof(*p) : 0);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
void TraderSpi::OnRspOptionSelfCloseAction(CThostFtdcInputOptionSelfCloseActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
119
|
+
ch_->push(ET_RspOptionSelfCloseAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputOptionSelfCloseAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
void TraderSpi::OnRspCombActionInsert(CThostFtdcInputCombActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
123
|
+
ch_->push(ET_RspCombActionInsert, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InputCombAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
void TraderSpi::OnRspQryOrder(CThostFtdcOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
127
|
+
ch_->push(ET_RspQryOrder, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Order : -1, p, p ? (int)sizeof(*p) : 0);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
void TraderSpi::OnRspQryTrade(CThostFtdcTradeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
131
|
+
ch_->push(ET_RspQryTrade, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Trade : -1, p, p ? (int)sizeof(*p) : 0);
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
void TraderSpi::OnRspQryInvestorPosition(CThostFtdcInvestorPositionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
135
|
+
ch_->push(ET_RspQryInvestorPosition, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorPosition : -1, p, p ? (int)sizeof(*p) : 0);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
void TraderSpi::OnRspQryTradingAccount(CThostFtdcTradingAccountField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
139
|
+
ch_->push(ET_RspQryTradingAccount, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TradingAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
void TraderSpi::OnRspQryInvestor(CThostFtdcInvestorField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
143
|
+
ch_->push(ET_RspQryInvestor, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Investor : -1, p, p ? (int)sizeof(*p) : 0);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
void TraderSpi::OnRspQryTradingCode(CThostFtdcTradingCodeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
147
|
+
ch_->push(ET_RspQryTradingCode, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TradingCode : -1, p, p ? (int)sizeof(*p) : 0);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
void TraderSpi::OnRspQryInstrumentMarginRate(CThostFtdcInstrumentMarginRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
151
|
+
ch_->push(ET_RspQryInstrumentMarginRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InstrumentMarginRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
void TraderSpi::OnRspQryInstrumentCommissionRate(CThostFtdcInstrumentCommissionRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
155
|
+
ch_->push(ET_RspQryInstrumentCommissionRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InstrumentCommissionRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
void TraderSpi::OnRspQryExchange(CThostFtdcExchangeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
159
|
+
ch_->push(ET_RspQryExchange, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Exchange : -1, p, p ? (int)sizeof(*p) : 0);
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
void TraderSpi::OnRspQryProduct(CThostFtdcProductField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
163
|
+
ch_->push(ET_RspQryProduct, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Product : -1, p, p ? (int)sizeof(*p) : 0);
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
void TraderSpi::OnRspQryInstrument(CThostFtdcInstrumentField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
167
|
+
ch_->push(ET_RspQryInstrument, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Instrument : -1, p, p ? (int)sizeof(*p) : 0);
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
void TraderSpi::OnRspQryDepthMarketData(CThostFtdcDepthMarketDataField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
171
|
+
ch_->push(ET_RspQryDepthMarketData, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_DepthMarketData : -1, p, p ? (int)sizeof(*p) : 0);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
void TraderSpi::OnRspQryTraderOffer(CThostFtdcTraderOfferField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
175
|
+
ch_->push(ET_RspQryTraderOffer, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TraderOffer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
void TraderSpi::OnRspQrySettlementInfo(CThostFtdcSettlementInfoField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
179
|
+
ch_->push(ET_RspQrySettlementInfo, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SettlementInfo : -1, p, p ? (int)sizeof(*p) : 0);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
void TraderSpi::OnRspQryTransferBank(CThostFtdcTransferBankField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
183
|
+
ch_->push(ET_RspQryTransferBank, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TransferBank : -1, p, p ? (int)sizeof(*p) : 0);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
void TraderSpi::OnRspQryInvestorPositionDetail(CThostFtdcInvestorPositionDetailField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
187
|
+
ch_->push(ET_RspQryInvestorPositionDetail, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorPositionDetail : -1, p, p ? (int)sizeof(*p) : 0);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
void TraderSpi::OnRspQryNotice(CThostFtdcNoticeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
191
|
+
ch_->push(ET_RspQryNotice, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Notice : -1, p, p ? (int)sizeof(*p) : 0);
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
void TraderSpi::OnRspQrySettlementInfoConfirm(CThostFtdcSettlementInfoConfirmField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
195
|
+
ch_->push(ET_RspQrySettlementInfoConfirm, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SettlementInfoConfirm : -1, p, p ? (int)sizeof(*p) : 0);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
void TraderSpi::OnRspQryInvestorPositionCombineDetail(CThostFtdcInvestorPositionCombineDetailField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
199
|
+
ch_->push(ET_RspQryInvestorPositionCombineDetail, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorPositionCombineDetail : -1, p, p ? (int)sizeof(*p) : 0);
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
void TraderSpi::OnRspQryCFMMCTradingAccountKey(CThostFtdcCFMMCTradingAccountKeyField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
203
|
+
ch_->push(ET_RspQryCFMMCTradingAccountKey, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_CFMMCTradingAccountKey : -1, p, p ? (int)sizeof(*p) : 0);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
void TraderSpi::OnRspQryEWarrantOffset(CThostFtdcEWarrantOffsetField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
207
|
+
ch_->push(ET_RspQryEWarrantOffset, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_EWarrantOffset : -1, p, p ? (int)sizeof(*p) : 0);
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
void TraderSpi::OnRspQryInvestorProductGroupMargin(CThostFtdcInvestorProductGroupMarginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
211
|
+
ch_->push(ET_RspQryInvestorProductGroupMargin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorProductGroupMargin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
void TraderSpi::OnRspQryExchangeMarginRate(CThostFtdcExchangeMarginRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
215
|
+
ch_->push(ET_RspQryExchangeMarginRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ExchangeMarginRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
void TraderSpi::OnRspQryExchangeMarginRateAdjust(CThostFtdcExchangeMarginRateAdjustField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
219
|
+
ch_->push(ET_RspQryExchangeMarginRateAdjust, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ExchangeMarginRateAdjust : -1, p, p ? (int)sizeof(*p) : 0);
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
void TraderSpi::OnRspQryExchangeRate(CThostFtdcExchangeRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
223
|
+
ch_->push(ET_RspQryExchangeRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ExchangeRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
void TraderSpi::OnRspQrySecAgentACIDMap(CThostFtdcSecAgentACIDMapField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
227
|
+
ch_->push(ET_RspQrySecAgentACIDMap, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SecAgentACIDMap : -1, p, p ? (int)sizeof(*p) : 0);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
void TraderSpi::OnRspQryProductExchRate(CThostFtdcProductExchRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
231
|
+
ch_->push(ET_RspQryProductExchRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ProductExchRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
void TraderSpi::OnRspQryProductGroup(CThostFtdcProductGroupField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
235
|
+
ch_->push(ET_RspQryProductGroup, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ProductGroup : -1, p, p ? (int)sizeof(*p) : 0);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
void TraderSpi::OnRspQryMMInstrumentCommissionRate(CThostFtdcMMInstrumentCommissionRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
239
|
+
ch_->push(ET_RspQryMMInstrumentCommissionRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_MMInstrumentCommissionRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
void TraderSpi::OnRspQryMMOptionInstrCommRate(CThostFtdcMMOptionInstrCommRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
243
|
+
ch_->push(ET_RspQryMMOptionInstrCommRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_MMOptionInstrCommRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
void TraderSpi::OnRspQryInstrumentOrderCommRate(CThostFtdcInstrumentOrderCommRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
247
|
+
ch_->push(ET_RspQryInstrumentOrderCommRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InstrumentOrderCommRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
void TraderSpi::OnRspQrySecAgentTradingAccount(CThostFtdcTradingAccountField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
251
|
+
ch_->push(ET_RspQrySecAgentTradingAccount, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TradingAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
void TraderSpi::OnRspQrySecAgentCheckMode(CThostFtdcSecAgentCheckModeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
255
|
+
ch_->push(ET_RspQrySecAgentCheckMode, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SecAgentCheckMode : -1, p, p ? (int)sizeof(*p) : 0);
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
void TraderSpi::OnRspQrySecAgentTradeInfo(CThostFtdcSecAgentTradeInfoField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
259
|
+
ch_->push(ET_RspQrySecAgentTradeInfo, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SecAgentTradeInfo : -1, p, p ? (int)sizeof(*p) : 0);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
void TraderSpi::OnRspQryOptionInstrTradeCost(CThostFtdcOptionInstrTradeCostField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
263
|
+
ch_->push(ET_RspQryOptionInstrTradeCost, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_OptionInstrTradeCost : -1, p, p ? (int)sizeof(*p) : 0);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
void TraderSpi::OnRspQryOptionInstrCommRate(CThostFtdcOptionInstrCommRateField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
267
|
+
ch_->push(ET_RspQryOptionInstrCommRate, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_OptionInstrCommRate : -1, p, p ? (int)sizeof(*p) : 0);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
void TraderSpi::OnRspQryExecOrder(CThostFtdcExecOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
271
|
+
ch_->push(ET_RspQryExecOrder, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ExecOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
void TraderSpi::OnRspQryForQuote(CThostFtdcForQuoteField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
275
|
+
ch_->push(ET_RspQryForQuote, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ForQuote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
void TraderSpi::OnRspQryQuote(CThostFtdcQuoteField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
279
|
+
ch_->push(ET_RspQryQuote, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Quote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
void TraderSpi::OnRspQryOptionSelfClose(CThostFtdcOptionSelfCloseField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
283
|
+
ch_->push(ET_RspQryOptionSelfClose, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_OptionSelfClose : -1, p, p ? (int)sizeof(*p) : 0);
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
void TraderSpi::OnRspQryInvestUnit(CThostFtdcInvestUnitField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
287
|
+
ch_->push(ET_RspQryInvestUnit, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestUnit : -1, p, p ? (int)sizeof(*p) : 0);
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
void TraderSpi::OnRspQryCombInstrumentGuard(CThostFtdcCombInstrumentGuardField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
291
|
+
ch_->push(ET_RspQryCombInstrumentGuard, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_CombInstrumentGuard : -1, p, p ? (int)sizeof(*p) : 0);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
void TraderSpi::OnRspQryCombAction(CThostFtdcCombActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
295
|
+
ch_->push(ET_RspQryCombAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_CombAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
void TraderSpi::OnRspQryTransferSerial(CThostFtdcTransferSerialField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
299
|
+
ch_->push(ET_RspQryTransferSerial, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TransferSerial : -1, p, p ? (int)sizeof(*p) : 0);
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
void TraderSpi::OnRspQryAccountregister(CThostFtdcAccountregisterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
303
|
+
ch_->push(ET_RspQryAccountregister, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Accountregister : -1, p, p ? (int)sizeof(*p) : 0);
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
void TraderSpi::OnRspError(CThostFtdcRspInfoField *e, int id, bool last) {
|
|
307
|
+
ch_->push(ET_RspError, id, last ? 1 : 0, eid(e), emsg(e), -1, nullptr, 0);
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
void TraderSpi::OnRtnOrder(CThostFtdcOrderField *p) {
|
|
311
|
+
if (p && risk_)
|
|
312
|
+
risk_->onOrderUpdate(p->FrontID, p->SessionID, p->OrderRef, p->InstrumentID, p->CombOffsetFlag[0] == '0', p->Direction == '0', p->OrderStatus, p->LimitPrice, p->VolumeTotalOriginal, p->VolumeTraded);
|
|
313
|
+
ch_->push(ET_RtnOrder, 0, -1, 0, "", p ? SID_Order : -1, p, p ? (int)sizeof(*p) : 0);
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
void TraderSpi::OnRtnTrade(CThostFtdcTradeField *p) {
|
|
317
|
+
if (p && risk_)
|
|
318
|
+
risk_->onTrade(p->InstrumentID, p->Direction == '0', p->OffsetFlag == '0', p->Price, p->Volume);
|
|
319
|
+
ch_->push(ET_RtnTrade, 0, -1, 0, "", p ? SID_Trade : -1, p, p ? (int)sizeof(*p) : 0);
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
void TraderSpi::OnErrRtnOrderInsert(CThostFtdcInputOrderField *p, CThostFtdcRspInfoField *e) {
|
|
323
|
+
if (p && risk_)
|
|
324
|
+
risk_->releaseReservation(p->OrderRef);
|
|
325
|
+
ch_->push(ET_ErrRtnOrderInsert, 0, -1, eid(e), emsg(e), p ? SID_InputOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
void TraderSpi::OnErrRtnOrderAction(CThostFtdcOrderActionField *p, CThostFtdcRspInfoField *e) {
|
|
329
|
+
ch_->push(ET_ErrRtnOrderAction, 0, -1, eid(e), emsg(e), p ? SID_OrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
void TraderSpi::OnRtnInstrumentStatus(CThostFtdcInstrumentStatusField *p) {
|
|
333
|
+
ch_->push(ET_RtnInstrumentStatus, 0, -1, 0, "", p ? SID_InstrumentStatus : -1, p, p ? (int)sizeof(*p) : 0);
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
void TraderSpi::OnRtnBulletin(CThostFtdcBulletinField *p) {
|
|
337
|
+
ch_->push(ET_RtnBulletin, 0, -1, 0, "", p ? SID_Bulletin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
void TraderSpi::OnRtnTradingNotice(CThostFtdcTradingNoticeInfoField *p) {
|
|
341
|
+
ch_->push(ET_RtnTradingNotice, 0, -1, 0, "", p ? SID_TradingNoticeInfo : -1, p, p ? (int)sizeof(*p) : 0);
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
void TraderSpi::OnRtnErrorConditionalOrder(CThostFtdcErrorConditionalOrderField *p) {
|
|
345
|
+
ch_->push(ET_RtnErrorConditionalOrder, 0, -1, 0, "", p ? SID_ErrorConditionalOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
void TraderSpi::OnRtnExecOrder(CThostFtdcExecOrderField *p) {
|
|
349
|
+
ch_->push(ET_RtnExecOrder, 0, -1, 0, "", p ? SID_ExecOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
void TraderSpi::OnErrRtnExecOrderInsert(CThostFtdcInputExecOrderField *p, CThostFtdcRspInfoField *e) {
|
|
353
|
+
ch_->push(ET_ErrRtnExecOrderInsert, 0, -1, eid(e), emsg(e), p ? SID_InputExecOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
void TraderSpi::OnErrRtnExecOrderAction(CThostFtdcExecOrderActionField *p, CThostFtdcRspInfoField *e) {
|
|
357
|
+
ch_->push(ET_ErrRtnExecOrderAction, 0, -1, eid(e), emsg(e), p ? SID_ExecOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
void TraderSpi::OnErrRtnForQuoteInsert(CThostFtdcInputForQuoteField *p, CThostFtdcRspInfoField *e) {
|
|
361
|
+
ch_->push(ET_ErrRtnForQuoteInsert, 0, -1, eid(e), emsg(e), p ? SID_InputForQuote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
void TraderSpi::OnRtnQuote(CThostFtdcQuoteField *p) {
|
|
365
|
+
ch_->push(ET_RtnQuote, 0, -1, 0, "", p ? SID_Quote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
void TraderSpi::OnErrRtnQuoteInsert(CThostFtdcInputQuoteField *p, CThostFtdcRspInfoField *e) {
|
|
369
|
+
ch_->push(ET_ErrRtnQuoteInsert, 0, -1, eid(e), emsg(e), p ? SID_InputQuote : -1, p, p ? (int)sizeof(*p) : 0);
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
void TraderSpi::OnErrRtnQuoteAction(CThostFtdcQuoteActionField *p, CThostFtdcRspInfoField *e) {
|
|
373
|
+
ch_->push(ET_ErrRtnQuoteAction, 0, -1, eid(e), emsg(e), p ? SID_QuoteAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
void TraderSpi::OnRtnForQuoteRsp(CThostFtdcForQuoteRspField *p) {
|
|
377
|
+
ch_->push(ET_RtnForQuoteRsp, 0, -1, 0, "", p ? SID_ForQuoteRsp : -1, p, p ? (int)sizeof(*p) : 0);
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
void TraderSpi::OnRtnCFMMCTradingAccountToken(CThostFtdcCFMMCTradingAccountTokenField *p) {
|
|
381
|
+
ch_->push(ET_RtnCFMMCTradingAccountToken, 0, -1, 0, "", p ? SID_CFMMCTradingAccountToken : -1, p, p ? (int)sizeof(*p) : 0);
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
void TraderSpi::OnErrRtnBatchOrderAction(CThostFtdcBatchOrderActionField *p, CThostFtdcRspInfoField *e) {
|
|
385
|
+
ch_->push(ET_ErrRtnBatchOrderAction, 0, -1, eid(e), emsg(e), p ? SID_BatchOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
void TraderSpi::OnRtnOptionSelfClose(CThostFtdcOptionSelfCloseField *p) {
|
|
389
|
+
ch_->push(ET_RtnOptionSelfClose, 0, -1, 0, "", p ? SID_OptionSelfClose : -1, p, p ? (int)sizeof(*p) : 0);
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
void TraderSpi::OnErrRtnOptionSelfCloseInsert(CThostFtdcInputOptionSelfCloseField *p, CThostFtdcRspInfoField *e) {
|
|
393
|
+
ch_->push(ET_ErrRtnOptionSelfCloseInsert, 0, -1, eid(e), emsg(e), p ? SID_InputOptionSelfClose : -1, p, p ? (int)sizeof(*p) : 0);
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
void TraderSpi::OnErrRtnOptionSelfCloseAction(CThostFtdcOptionSelfCloseActionField *p, CThostFtdcRspInfoField *e) {
|
|
397
|
+
ch_->push(ET_ErrRtnOptionSelfCloseAction, 0, -1, eid(e), emsg(e), p ? SID_OptionSelfCloseAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
void TraderSpi::OnRtnCombAction(CThostFtdcCombActionField *p) {
|
|
401
|
+
ch_->push(ET_RtnCombAction, 0, -1, 0, "", p ? SID_CombAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
void TraderSpi::OnErrRtnCombActionInsert(CThostFtdcInputCombActionField *p, CThostFtdcRspInfoField *e) {
|
|
405
|
+
ch_->push(ET_ErrRtnCombActionInsert, 0, -1, eid(e), emsg(e), p ? SID_InputCombAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
void TraderSpi::OnRspQryContractBank(CThostFtdcContractBankField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
409
|
+
ch_->push(ET_RspQryContractBank, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ContractBank : -1, p, p ? (int)sizeof(*p) : 0);
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
void TraderSpi::OnRspQryParkedOrder(CThostFtdcParkedOrderField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
413
|
+
ch_->push(ET_RspQryParkedOrder, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ParkedOrder : -1, p, p ? (int)sizeof(*p) : 0);
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
void TraderSpi::OnRspQryParkedOrderAction(CThostFtdcParkedOrderActionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
417
|
+
ch_->push(ET_RspQryParkedOrderAction, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ParkedOrderAction : -1, p, p ? (int)sizeof(*p) : 0);
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
void TraderSpi::OnRspQryTradingNotice(CThostFtdcTradingNoticeField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
421
|
+
ch_->push(ET_RspQryTradingNotice, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_TradingNotice : -1, p, p ? (int)sizeof(*p) : 0);
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
void TraderSpi::OnRspQryBrokerTradingParams(CThostFtdcBrokerTradingParamsField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
425
|
+
ch_->push(ET_RspQryBrokerTradingParams, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_BrokerTradingParams : -1, p, p ? (int)sizeof(*p) : 0);
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
void TraderSpi::OnRspQryBrokerTradingAlgos(CThostFtdcBrokerTradingAlgosField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
429
|
+
ch_->push(ET_RspQryBrokerTradingAlgos, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_BrokerTradingAlgos : -1, p, p ? (int)sizeof(*p) : 0);
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
void TraderSpi::OnRspQueryCFMMCTradingAccountToken(CThostFtdcQueryCFMMCTradingAccountTokenField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
433
|
+
ch_->push(ET_RspQueryCFMMCTradingAccountToken, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_QueryCFMMCTradingAccountToken : -1, p, p ? (int)sizeof(*p) : 0);
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
void TraderSpi::OnRtnFromBankToFutureByBank(CThostFtdcRspTransferField *p) {
|
|
437
|
+
ch_->push(ET_RtnFromBankToFutureByBank, 0, -1, 0, "", p ? SID_RspTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
void TraderSpi::OnRtnFromFutureToBankByBank(CThostFtdcRspTransferField *p) {
|
|
441
|
+
ch_->push(ET_RtnFromFutureToBankByBank, 0, -1, 0, "", p ? SID_RspTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
void TraderSpi::OnRtnRepealFromBankToFutureByBank(CThostFtdcRspRepealField *p) {
|
|
445
|
+
ch_->push(ET_RtnRepealFromBankToFutureByBank, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
void TraderSpi::OnRtnRepealFromFutureToBankByBank(CThostFtdcRspRepealField *p) {
|
|
449
|
+
ch_->push(ET_RtnRepealFromFutureToBankByBank, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
void TraderSpi::OnRtnFromBankToFutureByFuture(CThostFtdcRspTransferField *p) {
|
|
453
|
+
ch_->push(ET_RtnFromBankToFutureByFuture, 0, -1, 0, "", p ? SID_RspTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
void TraderSpi::OnRtnFromFutureToBankByFuture(CThostFtdcRspTransferField *p) {
|
|
457
|
+
ch_->push(ET_RtnFromFutureToBankByFuture, 0, -1, 0, "", p ? SID_RspTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
void TraderSpi::OnRtnRepealFromBankToFutureByFutureManual(CThostFtdcRspRepealField *p) {
|
|
461
|
+
ch_->push(ET_RtnRepealFromBankToFutureByFutureManual, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
void TraderSpi::OnRtnRepealFromFutureToBankByFutureManual(CThostFtdcRspRepealField *p) {
|
|
465
|
+
ch_->push(ET_RtnRepealFromFutureToBankByFutureManual, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
void TraderSpi::OnRtnQueryBankBalanceByFuture(CThostFtdcNotifyQueryAccountField *p) {
|
|
469
|
+
ch_->push(ET_RtnQueryBankBalanceByFuture, 0, -1, 0, "", p ? SID_NotifyQueryAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
470
|
+
}
|
|
471
|
+
|
|
472
|
+
void TraderSpi::OnErrRtnBankToFutureByFuture(CThostFtdcReqTransferField *p, CThostFtdcRspInfoField *e) {
|
|
473
|
+
ch_->push(ET_ErrRtnBankToFutureByFuture, 0, -1, eid(e), emsg(e), p ? SID_ReqTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
void TraderSpi::OnErrRtnFutureToBankByFuture(CThostFtdcReqTransferField *p, CThostFtdcRspInfoField *e) {
|
|
477
|
+
ch_->push(ET_ErrRtnFutureToBankByFuture, 0, -1, eid(e), emsg(e), p ? SID_ReqTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
void TraderSpi::OnErrRtnRepealBankToFutureByFutureManual(CThostFtdcReqRepealField *p, CThostFtdcRspInfoField *e) {
|
|
481
|
+
ch_->push(ET_ErrRtnRepealBankToFutureByFutureManual, 0, -1, eid(e), emsg(e), p ? SID_ReqRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
482
|
+
}
|
|
483
|
+
|
|
484
|
+
void TraderSpi::OnErrRtnRepealFutureToBankByFutureManual(CThostFtdcReqRepealField *p, CThostFtdcRspInfoField *e) {
|
|
485
|
+
ch_->push(ET_ErrRtnRepealFutureToBankByFutureManual, 0, -1, eid(e), emsg(e), p ? SID_ReqRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
void TraderSpi::OnErrRtnQueryBankBalanceByFuture(CThostFtdcReqQueryAccountField *p, CThostFtdcRspInfoField *e) {
|
|
489
|
+
ch_->push(ET_ErrRtnQueryBankBalanceByFuture, 0, -1, eid(e), emsg(e), p ? SID_ReqQueryAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
void TraderSpi::OnRtnRepealFromBankToFutureByFuture(CThostFtdcRspRepealField *p) {
|
|
493
|
+
ch_->push(ET_RtnRepealFromBankToFutureByFuture, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
494
|
+
}
|
|
495
|
+
|
|
496
|
+
void TraderSpi::OnRtnRepealFromFutureToBankByFuture(CThostFtdcRspRepealField *p) {
|
|
497
|
+
ch_->push(ET_RtnRepealFromFutureToBankByFuture, 0, -1, 0, "", p ? SID_RspRepeal : -1, p, p ? (int)sizeof(*p) : 0);
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
void TraderSpi::OnRspFromBankToFutureByFuture(CThostFtdcReqTransferField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
501
|
+
ch_->push(ET_RspFromBankToFutureByFuture, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ReqTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
void TraderSpi::OnRspFromFutureToBankByFuture(CThostFtdcReqTransferField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
505
|
+
ch_->push(ET_RspFromFutureToBankByFuture, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ReqTransfer : -1, p, p ? (int)sizeof(*p) : 0);
|
|
506
|
+
}
|
|
507
|
+
|
|
508
|
+
void TraderSpi::OnRspQueryBankAccountMoneyByFuture(CThostFtdcReqQueryAccountField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
509
|
+
ch_->push(ET_RspQueryBankAccountMoneyByFuture, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_ReqQueryAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
510
|
+
}
|
|
511
|
+
|
|
512
|
+
void TraderSpi::OnRtnOpenAccountByBank(CThostFtdcOpenAccountField *p) {
|
|
513
|
+
ch_->push(ET_RtnOpenAccountByBank, 0, -1, 0, "", p ? SID_OpenAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
514
|
+
}
|
|
515
|
+
|
|
516
|
+
void TraderSpi::OnRtnCancelAccountByBank(CThostFtdcCancelAccountField *p) {
|
|
517
|
+
ch_->push(ET_RtnCancelAccountByBank, 0, -1, 0, "", p ? SID_CancelAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
void TraderSpi::OnRtnChangeAccountByBank(CThostFtdcChangeAccountField *p) {
|
|
521
|
+
ch_->push(ET_RtnChangeAccountByBank, 0, -1, 0, "", p ? SID_ChangeAccount : -1, p, p ? (int)sizeof(*p) : 0);
|
|
522
|
+
}
|
|
523
|
+
|
|
524
|
+
void TraderSpi::OnRspQryClassifiedInstrument(CThostFtdcInstrumentField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
525
|
+
ch_->push(ET_RspQryClassifiedInstrument, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_Instrument : -1, p, p ? (int)sizeof(*p) : 0);
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
void TraderSpi::OnRspQryCombPromotionParam(CThostFtdcCombPromotionParamField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
529
|
+
ch_->push(ET_RspQryCombPromotionParam, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_CombPromotionParam : -1, p, p ? (int)sizeof(*p) : 0);
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
void TraderSpi::OnRspQryRiskSettleInvstPosition(CThostFtdcRiskSettleInvstPositionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
533
|
+
ch_->push(ET_RspQryRiskSettleInvstPosition, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RiskSettleInvstPosition : -1, p, p ? (int)sizeof(*p) : 0);
|
|
534
|
+
}
|
|
535
|
+
|
|
536
|
+
void TraderSpi::OnRspQryRiskSettleProductStatus(CThostFtdcRiskSettleProductStatusField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
537
|
+
ch_->push(ET_RspQryRiskSettleProductStatus, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RiskSettleProductStatus : -1, p, p ? (int)sizeof(*p) : 0);
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
void TraderSpi::OnRspQrySPBMFutureParameter(CThostFtdcSPBMFutureParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
541
|
+
ch_->push(ET_RspQrySPBMFutureParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMFutureParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
void TraderSpi::OnRspQrySPBMOptionParameter(CThostFtdcSPBMOptionParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
545
|
+
ch_->push(ET_RspQrySPBMOptionParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMOptionParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
void TraderSpi::OnRspQrySPBMIntraParameter(CThostFtdcSPBMIntraParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
549
|
+
ch_->push(ET_RspQrySPBMIntraParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMIntraParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
void TraderSpi::OnRspQrySPBMInterParameter(CThostFtdcSPBMInterParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
553
|
+
ch_->push(ET_RspQrySPBMInterParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMInterParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
554
|
+
}
|
|
555
|
+
|
|
556
|
+
void TraderSpi::OnRspQrySPBMPortfDefinition(CThostFtdcSPBMPortfDefinitionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
557
|
+
ch_->push(ET_RspQrySPBMPortfDefinition, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMPortfDefinition : -1, p, p ? (int)sizeof(*p) : 0);
|
|
558
|
+
}
|
|
559
|
+
|
|
560
|
+
void TraderSpi::OnRspQrySPBMInvestorPortfDef(CThostFtdcSPBMInvestorPortfDefField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
561
|
+
ch_->push(ET_RspQrySPBMInvestorPortfDef, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMInvestorPortfDef : -1, p, p ? (int)sizeof(*p) : 0);
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
void TraderSpi::OnRspQryInvestorPortfMarginRatio(CThostFtdcInvestorPortfMarginRatioField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
565
|
+
ch_->push(ET_RspQryInvestorPortfMarginRatio, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorPortfMarginRatio : -1, p, p ? (int)sizeof(*p) : 0);
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
void TraderSpi::OnRspQryInvestorProdSPBMDetail(CThostFtdcInvestorProdSPBMDetailField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
569
|
+
ch_->push(ET_RspQryInvestorProdSPBMDetail, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorProdSPBMDetail : -1, p, p ? (int)sizeof(*p) : 0);
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
void TraderSpi::OnRspQryInvestorCommoditySPMMMargin(CThostFtdcInvestorCommoditySPMMMarginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
573
|
+
ch_->push(ET_RspQryInvestorCommoditySPMMMargin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorCommoditySPMMMargin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
void TraderSpi::OnRspQryInvestorCommodityGroupSPMMMargin(CThostFtdcInvestorCommodityGroupSPMMMarginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
577
|
+
ch_->push(ET_RspQryInvestorCommodityGroupSPMMMargin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorCommodityGroupSPMMMargin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
578
|
+
}
|
|
579
|
+
|
|
580
|
+
void TraderSpi::OnRspQrySPMMInstParam(CThostFtdcSPMMInstParamField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
581
|
+
ch_->push(ET_RspQrySPMMInstParam, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPMMInstParam : -1, p, p ? (int)sizeof(*p) : 0);
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
void TraderSpi::OnRspQrySPMMProductParam(CThostFtdcSPMMProductParamField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
585
|
+
ch_->push(ET_RspQrySPMMProductParam, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPMMProductParam : -1, p, p ? (int)sizeof(*p) : 0);
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
void TraderSpi::OnRspQrySPBMAddOnInterParameter(CThostFtdcSPBMAddOnInterParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
589
|
+
ch_->push(ET_RspQrySPBMAddOnInterParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_SPBMAddOnInterParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
590
|
+
}
|
|
591
|
+
|
|
592
|
+
void TraderSpi::OnRspQryRCAMSCombProductInfo(CThostFtdcRCAMSCombProductInfoField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
593
|
+
ch_->push(ET_RspQryRCAMSCombProductInfo, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSCombProductInfo : -1, p, p ? (int)sizeof(*p) : 0);
|
|
594
|
+
}
|
|
595
|
+
|
|
596
|
+
void TraderSpi::OnRspQryRCAMSInstrParameter(CThostFtdcRCAMSInstrParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
597
|
+
ch_->push(ET_RspQryRCAMSInstrParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSInstrParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
598
|
+
}
|
|
599
|
+
|
|
600
|
+
void TraderSpi::OnRspQryRCAMSIntraParameter(CThostFtdcRCAMSIntraParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
601
|
+
ch_->push(ET_RspQryRCAMSIntraParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSIntraParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
void TraderSpi::OnRspQryRCAMSInterParameter(CThostFtdcRCAMSInterParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
605
|
+
ch_->push(ET_RspQryRCAMSInterParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSInterParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
void TraderSpi::OnRspQryRCAMSShortOptAdjustParam(CThostFtdcRCAMSShortOptAdjustParamField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
609
|
+
ch_->push(ET_RspQryRCAMSShortOptAdjustParam, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSShortOptAdjustParam : -1, p, p ? (int)sizeof(*p) : 0);
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
void TraderSpi::OnRspQryRCAMSInvestorCombPosition(CThostFtdcRCAMSInvestorCombPositionField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
613
|
+
ch_->push(ET_RspQryRCAMSInvestorCombPosition, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RCAMSInvestorCombPosition : -1, p, p ? (int)sizeof(*p) : 0);
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
void TraderSpi::OnRspQryInvestorProdRCAMSMargin(CThostFtdcInvestorProdRCAMSMarginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
617
|
+
ch_->push(ET_RspQryInvestorProdRCAMSMargin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorProdRCAMSMargin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
void TraderSpi::OnRspQryRULEInstrParameter(CThostFtdcRULEInstrParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
621
|
+
ch_->push(ET_RspQryRULEInstrParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RULEInstrParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
622
|
+
}
|
|
623
|
+
|
|
624
|
+
void TraderSpi::OnRspQryRULEIntraParameter(CThostFtdcRULEIntraParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
625
|
+
ch_->push(ET_RspQryRULEIntraParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RULEIntraParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
void TraderSpi::OnRspQryRULEInterParameter(CThostFtdcRULEInterParameterField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
629
|
+
ch_->push(ET_RspQryRULEInterParameter, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_RULEInterParameter : -1, p, p ? (int)sizeof(*p) : 0);
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
void TraderSpi::OnRspQryInvestorProdRULEMargin(CThostFtdcInvestorProdRULEMarginField *p, CThostFtdcRspInfoField *e, int id, bool last) {
|
|
633
|
+
ch_->push(ET_RspQryInvestorProdRULEMargin, id, last ? 1 : 0, eid(e), emsg(e), p ? SID_InvestorProdRULEMargin : -1, p, p ? (int)sizeof(*p) : 0);
|
|
634
|
+
}
|
|
635
|
+
|
|
636
|
+
} // namespace ctp
|