public Match Get(IParams param) { MatchParameters matchParameters = param as MatchParameters; string endpoint = matchParameters.EndPoint; DateTime timestamp = matchParameters.Timestamp; serverService.Get(endpoint); return(matchRepository.Get(endpoint, timestamp)); }
public MatchInfo Get(string endpoint, DateTime timestamp) { try { var param = new MatchParameters(endpoint, timestamp); return(matchService.Get(param).Results); } catch (NullReferenceException ex) { var response = new HttpResponseMessage(HttpStatusCode.NotFound); if (Request != null) { response.RequestMessage = Request; } response.Content = new StringContent(ex.Message); throw new HttpResponseException(response); } }