/// <remarks/> public void getMarketAsync(GetMarketReq request, object userState) { if ((this.getMarketOperationCompleted == null)) { this.getMarketOperationCompleted = new System.Threading.SendOrPostCallback(this.OngetMarketOperationCompleted); } this.InvokeAsync("getMarket", new object[] { request}, this.getMarketOperationCompleted, userState); }
public GetMarketResp getMarket(GetMarketReq request) { object[] results = this.Invoke("getMarket", new object[] { request}); return ((GetMarketResp)(results[0])); }
/// <remarks/> public void getMarketAsync(GetMarketReq request) { this.getMarketAsync(request, null); }
/// <summary> /// The API GetMarket service allows the customer to input a /// Market ID and retrieve all static market data for the /// market requested. To get a Market ID for the betting /// market associated with an event you are interested in, /// use the GetEvents command. /// </summary> /// <param name="exchangeId"></param> /// <param name="marketId"></param> /// <returns></returns> public BetfairExchangeAPI.Market GetMarket(int exchangeId, int marketId) { const string serviceName = "GetMarket"; Console.WriteLine("{0}$ API_SERVICE {1}", DateTime.Now, serviceName); var request = new GetMarketReq { includeCouponLinks = false, marketId = marketId, header = ((BetfairExchangeAPI.APIRequestHeader) GetHeader(false)) }; GetMarketResp response = _bfExchangeService[exchangeId].getMarket(request); ValidateAPIResponse(serviceName, Convert.ToString(response.header.errorCode), Convert.ToString(response.errorCode), response.header.sessionToken); return response.market; }