Add getTimegridUnits

This commit is contained in:
Timo Ley 2020-01-18 23:40:30 +01:00
parent 9e23125522
commit c6562f7db3
2 changed files with 25 additions and 0 deletions

View file

@ -189,5 +189,13 @@ public class UntisClient {
}
}
public TimegridResponse getTimegridUnits() throws APIRequestException {
try {
return client.invoke("getTimegridUnits", new Object[0], TimegridResponse.class);
} catch (Throwable e) {
throw new APIRequestException(e);
}
}
}

View file

@ -0,0 +1,17 @@
package ley.untis.data;
import java.util.ArrayList;
public class TimegridResponse extends ArrayList<TimegridResponse.Day> {
public static class Day {
public int day;
public TimeUnit[] timeUnits;
public static class TimeUnit {
public int startTime;
public int endTime;
public String name;
}
}
}