Android SDK Logging
ENGAGE® Android SDK Logging
The ENGAGE SDK includes a logging interceptor that will allow the host app to access the logs that come from the SDK.
import android.app.Application
import com.firstorion.engage.core.EngageApp
import com.firstorion.engage.core.IEngageLoggingInterceptor
class MainApplication: Application(), IEngageLoggingInterceptor {
override fun onCreate(){
super.onCreate()
//Enable logging of Engage SDK
EngageApp.Settings.setLoggingInterceptor(this)
}
override fun intercept(message: String, level: Int){
println("engage.app $message")
}
}
The ENGAGE SDK also allows you to set the logging level. Logging level sets the minimum Logging Level as defined in Android’s Log class. Default level is set to Log.VERBOSE:
EngageApp.Settings.setMinimumLoggingLevel(Log.WARNING) // or Log.ERROR etc.
Updated 5 months ago
What’s Next