forked from jasonweiyi/XAPI2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathIXApi.cs
More file actions
76 lines (62 loc) · 2.23 KB
/
Copy pathIXApi.cs
File metadata and controls
76 lines (62 loc) · 2.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
namespace XAPI.Interface
{
[ComVisible(false)]
public interface IXApi
{
DelegateOnConnectionStatus OnConnectionStatus { get; set; }
DelegateOnRtnError OnRtnError { get; set; }
DelegateOnLog OnLog { get; set; }
void Connect();
void Disconnect();
void ReqQuery(QueryType type, ref ReqQueryField query);
ApiType GetApiTypes { get;}
string GetApiName { get;}
string GetApiVersion { get;}
}
[ComVisible(false)]
public interface IXMarketData
{
DelegateOnRtnDepthMarketData OnRtnDepthMarketData{ get; set; }
void Subscribe(string szInstrument, string szExchange);
void Unsubscribe(string szInstrument, string szExchange);
}
[ComVisible(false)]
public interface IXInstrument
{
DelegateOnRspQryInstrument OnRspQryInstrument { get; set; }
}
[ComVisible(false)]
public interface IXQuery
{
DelegateOnRspQryTradingAccount OnRspQryTradingAccount { get; set; }
DelegateOnRspQryInvestorPosition OnRspQryInvestorPosition { get; set; }
DelegateOnRspQrySettlementInfo OnRspQrySettlementInfo { get; set; }
DelegateOnRspQryOrder OnRspQryOrder { get; set; }
DelegateOnRspQryTrade OnRspQryTrade { get; set; }
DelegateOnRspQryQuote OnRspQryQuote { get; set; }
}
[ComVisible(false)]
public interface IXTrade
{
DelegateOnRtnOrder OnRtnOrder { get; set; }
DelegateOnRtnTrade OnRtnTrade { get; set; }
DelegateOnRtnQuote OnRtnQuote { get; set; }
string SendOrder(ref OrderField[] orders);
string CancelOrder(string[] szId);
string SendQuote(ref QuoteField quote);
string CancelQuote(string szId);
}
[ComVisible(false)]
public interface IXHistoricalData
{
DelegateOnRspQryHistoricalTicks OnRspQryHistoricalTicks { get; set; }
DelegateOnRspQryHistoricalBars OnRspQryHistoricalBars { get; set; }
//int ReqQryHistoricalTicks(ref HistoricalDataRequestField request);
//int ReqQryHistoricalBars(ref HistoricalDataRequestField request);
}
}