January 2018
Intermediate to advanced
434 pages
14h 1m
English
Anko is an Android library that uses Kotlin and makes Android development easier with the help of extension functions. It provides Anko-logger, which you can use if you don’t want to write your own logger. It is included in anko-commons, which also has a lot of interesting things to make it worthwhile to include it in your Android projects that use Kotlin.
In Anko, a standard implementation of logger will look something like this:
class SomeActivity : Activity(), AnkoLogger { private fun someMethod() { info("London is the capital of Great Britain") debug(5) // .toString() method will be executed warn(null) // "null" will be printed }}
As you can see, you just need to implement AnkoLogger and you are done.
Each method has two ...
Read now
Unlock full access