This project is used to optimize Java Service Provider Interface on Android.
The transformer depends Booster Framework, so, the booster-gradle-plugin should be contained in classpath of buildscript:
buildscript {
ext.kotlin_version = "1.3.50"
repositories {
mavenLocal()
mavenCentral()
google()
jcenter()
}
dependencies {
classpath("com.android.tools.build:gradle:3.5.0")
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath("com.didiglobal.booster:booster-gradle-plugin:1.3.1")
classpath("io.johnsonlee.spi:booster-transform-service-loader:1.0.0")
}
}
Then apply booster gradle plugin:
apply plugin: "com.android.application"
apply plugin: "kotlin-android"
apply plugin: "kotlin-android-extensions"
apply plugin: 'kotlin-kapt'
apply plugin: "com.didiglobal.booster"
Here is the example project