Esempio n. 1
0
int TdApi::reqUserLogin(dict req, int nRequestID)
{
	CThostFtdcReqUserLoginField myreq = CThostFtdcReqUserLoginField();
	memset(&myreq, 0, sizeof(myreq));
	getChar(req, "lastLoginTime", myreq.lastLoginTime);
	getChar(req, "tradeDate", myreq.tradeDate);
	getChar(req, "ipGatewayAddress", myreq.ipGatewayAddress);
	getChar(req, "localOrderNo", myreq.localOrderNo);
	getInt(req, "loginbatch", &myreq.loginbatch);
	getChar(req, "memberID", myreq.memberID);
	getInt(req, "loginType", &myreq.loginType);
	getInt(req, "portGateway", &myreq.portGateway);
	getChar(req, "obligate", myreq.obligate);
	getInt(req, "gateWayCurLinkNum", &myreq.gateWayCurLinkNum);
	getChar(req, "lastLoginDate", myreq.lastLoginDate);
	getInt(req, "machineID", &myreq.machineID);
	getChar(req, "msg", myreq.msg);
	getChar(req, "lastLoginIp", myreq.lastLoginIp);
	getChar(req, "password", myreq.password);
	getChar(req, "gateWayYYBDB", myreq.gateWayYYBDB);
	getChar(req, "clientName", myreq.clientName);
	getChar(req, "accountID", myreq.accountID);
	int i = this->api->ReqUserLogin(&myreq, nRequestID);
	return i;
};
Esempio n. 2
0
int MdApi::reqUserLogin(dict req, int nRequestID)
{
	CThostFtdcReqUserLoginField myreq = CThostFtdcReqUserLoginField();
	memset(&myreq, 0, sizeof(myreq));
	getStr(req, "MacAddress", myreq.MacAddress);
	getStr(req, "UserProductInfo", myreq.UserProductInfo);
	getStr(req, "UserID", myreq.UserID);
	getStr(req, "TradingDay", myreq.TradingDay);
	getStr(req, "InterfaceProductInfo", myreq.InterfaceProductInfo);
	getStr(req, "BrokerID", myreq.BrokerID);
	getStr(req, "ClientIPAddress", myreq.ClientIPAddress);
	getStr(req, "OneTimePassword", myreq.OneTimePassword);
	getStr(req, "ProtocolInfo", myreq.ProtocolInfo);
	getStr(req, "Password", myreq.Password);
	int i = this->api->ReqUserLogin(&myreq, nRequestID);
	return i;
};