forked from heber/xTrader
/
xTrader.h
64 lines (54 loc) · 1.48 KB
/
xTrader.h
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
// xTrader.h : main header file for the XTRADER application
//
#pragma once
#ifndef __AFXWIN_H__
#error include 'stdafx.h' before including this file for PCH
#endif
#include "resource.h" // main symbols
#include "mdspi.h"
#include "traderspi.h"
/////////////////////////////////////////////////////////////////////////////
// CXTraderApp:
// See xTrader.cpp for the implementation of this class
//
class CXTraderApp : public CWinApp
{
public:
CXTraderApp();
~CXTraderApp();
public:
CThostFtdcMdApi* m_MApi;
CThostFtdcTraderApi* m_TApi;
CtpMdSpi* m_cQ;
CtpTraderSpi* m_cT;
//int m_nReq;
//char* m_szErr;
CString m_szTitle;
public:
TThostFtdcBrokerIDType m_sBROKER_ID;
TThostFtdcInvestorIDType m_sINVESTOR_ID;
TThostFtdcPasswordType m_sPASSWORD;
char m_szInst[MAX_PATH];
CString m_szNtpSvr;
int m_ixPos,m_iyPos,m_iWidth,m_iHeight;
vector<BKRPARA*> m_BkrParaVec;
public:
void CreateApi();
void ReleaseApi();
void LoadConfig();
void ParseXml(CString strDir);
CString GetBkrById(TThostFtdcBrokerIDType szBkrId);
BOOL AddSvr2Ar(CStringArray& szArTs,CStringArray& szArMd,CString szGrpName,int iIndex);
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CXTraderApp)
public:
virtual BOOL InitInstance();
virtual int ExitInstance();
//}}AFX_VIRTUAL
//{{AFX_MSG(CXTraderApp)
// NOTE - the ClassWizard will add and remove member functions here.
// DO NOT EDIT what you see in these blocks of generated code !
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};