mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-13 11:17:33 +01:00
Add further getters, converting the data to other units
This commit is contained in:
parent
9fb2e1620e
commit
070f3fa66f
@ -99,6 +99,10 @@ public class CalendarEvents {
|
|||||||
return begin;
|
return begin;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getBeginSeconds() {
|
||||||
|
return (int)(begin/1000);
|
||||||
|
}
|
||||||
|
|
||||||
public long getEnd() {
|
public long getEnd() {
|
||||||
return end;
|
return end;
|
||||||
}
|
}
|
||||||
@ -107,6 +111,14 @@ public class CalendarEvents {
|
|||||||
return end - begin;
|
return end - begin;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getDurationSeconds() {
|
||||||
|
return (int)((getDuration())/1000);
|
||||||
|
}
|
||||||
|
|
||||||
|
public short getDurationMinutes() {
|
||||||
|
return (short)(getDurationSeconds()/60);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public long getId() {
|
public long getId() {
|
||||||
return id;
|
return id;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user