+ public Rounds getEventRounds(int eventId) throws APIException {
+ Rounds rounds;
+ try {
+ rounds = new JsonRounds(
+ GSON.fromJson(
+ JsonStringToken.token(
+ RequestType.request(
+ RequestType.EVENT_ROUNDS,
+ eventId
+ )
+ ),
+ JsonRound[].class
+ )
+ );
+ } catch (RequestException e) {
+ throw new APIException(
+ APIException.Type.REQUEST, e.getMessage()
+ );
+ }
+ return rounds;
+ }
+
+ @Override
+ public Seedings getEventSeedings(int eventId) throws APIException {
+ Seedings seedings;
+ try {
+ seedings = new JsonSeedings(
+ GSON.fromJson(
+ JsonStringToken.token(
+ RequestType.request(
+ RequestType.EVENT_SEEDING,
+ eventId
+ )
+ ),
+ JsonSeeding[].class
+ )
+ );
+ } catch (RequestException e) {
+ throw new APIException(
+ APIException.Type.REQUEST, e.getMessage()
+ );
+ }
+ return seedings;
+ }
+
+ @Override