Ejemplo n.º 1
0
        public async Task <IApiResponse <PagedLocationRankingPlayers> > GetPlayerRankingsResponseAsync(LocationsEnum locationEnum, LocationFilter locationFilter = null)
        {
            if (locationFilter?.After != null && locationFilter.Before != null)
            {
                throw new InvalidOperationException("Only after or before can be specified for a request, not both.");
            }

            IApiResponse <PagedLocationRankingPlayers> apiResponse = await RestApiClient.GetApiResponseAsync <PagedLocationRankingPlayers>(
                UrlPathBuilder.GetRankingsPlayerUrl((int)locationEnum), locationFilter?.ToQueryParams());

            return(apiResponse);
        }