From 6857a59a7c39b0bb0daa0afe57cc200055c103de Mon Sep 17 00:00:00 2001 From: Pazus Date: Sat, 17 Dec 2016 18:02:26 +0300 Subject: [PATCH] removed unsupported params --- .../request/dota2/GetMatchHistoryRequest.java | 20 ------------------- .../SteamWebApiRequestBuilderTest.java | 4 ---- 2 files changed, 24 deletions(-) diff --git a/src/main/java/com/lukaspradel/steamapi/webapi/request/dota2/GetMatchHistoryRequest.java b/src/main/java/com/lukaspradel/steamapi/webapi/request/dota2/GetMatchHistoryRequest.java index cce8212..3fdd6b5 100644 --- a/src/main/java/com/lukaspradel/steamapi/webapi/request/dota2/GetMatchHistoryRequest.java +++ b/src/main/java/com/lukaspradel/steamapi/webapi/request/dota2/GetMatchHistoryRequest.java @@ -105,16 +105,6 @@ public GetMatchHistoryRequestBuilder skill(Skill skill) { return this; } - public GetMatchHistoryRequestBuilder dateMin(Date dateMin) { - this.dateMin = dateMin.getTime() / 1000L; - return this; - } - - public GetMatchHistoryRequestBuilder dateMax(Date dateMax) { - this.dateMax = dateMax.getTime() / 1000L; - return this; - } - public GetMatchHistoryRequestBuilder minPlayers(Integer minPlayers) { this.minPlayers = minPlayers; return this; @@ -151,8 +141,6 @@ public GetMatchHistoryRequestBuilder tournamentGamesOnly(boolean tournamentGames public static final String REQUEST_PARAM_HERO_ID = "hero_id"; public static final String REQUEST_PARAM_GAME_MODE = "game_mode"; public static final String REQUEST_PARAM_SKILL = "skill"; - public static final String REQUEST_PARAM_DATE_MIN = "date_min"; - public static final String REQUEST_PARAM_DATE_MAX = "date_max"; public static final String REQUEST_PARAM_MIN_PLAYERS = "min_players"; public static final String REQUEST_PARAM_ACCOUNT_ID = "account_id"; public static final String REQUEST_PARAM_LEAGUE_ID = "league_id"; @@ -189,14 +177,6 @@ public GetMatchHistoryRequest buildRequest() { addParameter(REQUEST_PARAM_SKILL,skill.toString()); } - if (dateMin != null) { - addParameter(REQUEST_PARAM_DATE_MIN,dateMin); - } - - if (dateMax != null) { - addParameter(REQUEST_PARAM_DATE_MAX,dateMax); - } - if (minPlayers != null) { addParameter(REQUEST_PARAM_MIN_PLAYERS,minPlayers); } diff --git a/src/test/java/com/lukaspradel/steamapi/webapi/request/builders/SteamWebApiRequestBuilderTest.java b/src/test/java/com/lukaspradel/steamapi/webapi/request/builders/SteamWebApiRequestBuilderTest.java index 5328467..e87968d 100644 --- a/src/test/java/com/lukaspradel/steamapi/webapi/request/builders/SteamWebApiRequestBuilderTest.java +++ b/src/test/java/com/lukaspradel/steamapi/webapi/request/builders/SteamWebApiRequestBuilderTest.java @@ -33,8 +33,6 @@ public void testGetMatchHistoryRequestBuilder() { GetMatchHistoryRequest request = new GetMatchHistoryRequestBuilder() .accountId("123") - .dateMin(startDate.getTime()) - .dateMax(endDate.getTime()) .gameMode(GetMatchHistoryRequest.GameMode.ALL_PICK) .heroIdsFilter(heroIdsFilter) .leagueId("5") @@ -53,8 +51,6 @@ public void testGetMatchHistoryRequestBuilder() { Map parameters = request.getParameters(); assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_ACCOUNT_ID),"123"); - assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_DATE_MIN),String.valueOf(startDate.getTimeInMillis()/1000L)); - assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_DATE_MAX),String.valueOf(endDate.getTimeInMillis()/1000L)); assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_GAME_MODE),"1"); assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_HERO_ID),"1,2"); assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_LEAGUE_ID),"5");