Check versions without typing a bunch of easy to typo nonsense. Uses IntDef for source completion and static methods for easy to read conditionals.
Naturally describe what you would like to test much like testing frameworks.
if (Is.greaterThan(LOLLIPOP)) {
...
}
if (Is.lessThanOrEqual(JELLY_BEAN_MR1)) {
...
}
For the SDK versions you can either implement the SdkVersion
interface or use the definitions directly SdkVersion.MARSHMALLOW
.
Use mavenCentral()
repository.
compile 'com.ToxicBakery.android.version:versions:+@aar'