mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2025-01-27 09:01:38 +01:00
Merge branch 'master' of codeberg.org:Freeyourgadget/Gadgetbridge into multi-device-support
This commit is contained in:
commit
03344a2a52
@ -35,6 +35,26 @@ public class Version implements Comparable<Version> {
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
public boolean smallerOrEqualThan(Version that){
|
||||
return !greaterThan(that);
|
||||
}
|
||||
|
||||
public boolean greaterOrEqualThan(Version that){
|
||||
return !smallerThan(that);
|
||||
}
|
||||
|
||||
public boolean smallerThan(Version that){
|
||||
return compareTo(that) == -1;
|
||||
}
|
||||
|
||||
public boolean greaterThan(Version that){
|
||||
return compareTo(that) == 1;
|
||||
}
|
||||
|
||||
public boolean sameAs(Version that){
|
||||
return compareTo(that) == 0;
|
||||
}
|
||||
|
||||
@Override public int compareTo(Version that) {
|
||||
if(that == null)
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user