Posted on

About Kotlin

Demystifying the inline keyword (https://www.kotlindevelopment.com/inline-noinline-crossinline-reified/)

Parcelable in Kotlin (https://proandroiddev.com/parcelable-in-kotlin-here-comes-parcelize-b998d5a5fcac)

Kotlin: When to Use Lazy or Lateinit (https://www.bignerdranch.com/blog/kotlin-when-to-use-lazy-or-lateinit/)

Mocking Kotlin classes with Mockito — the fast way (https://engineering.21buttons.com/mocking-kotlin-classes-with-mockito-the-fast-way-631824edd5ba)

Lessons from my first multiplatform Kotlin project (https://blog.kotlin-academy.com/lessons-from-my-first-multiplatform-kotlin-project-d4e311f15874)

How to Develop Android Image Gallery App in Kotlin (http://developine.com/develop-android-image-gallery-app-kotlin-with-source-code/)

Computer Vision with Kotlin (https://android.jlelse.eu/6-steps-to-add-computer-vision-super-powers-to-your-kotlin-android-app-ed199f478f22)

Kotlin’s let extension function (https://android.jlelse.eu/lets-talk-about-kotlin-s-let-extension-function-5911213cf8b9)

Listeners with several functions in Kotlin. How to make them shine? (https://antonioleiva.com/listeners-several-functions-kotlin/)

Android Testing with Kotlin (https://fernandocejas.com/2017/02/03/android-testing-with-kotlin/)

Mastering Kotlin standard functions: run, with, let, also and apply (https://android.jlelse.eu/mastering-kotlin-standard-functions-run-with-let-also-and-apply-9cd334b0ef84)

Don’t use lambdas as listeners in Kotlin (http://galex.co.il/2017/11/04/Dont_Use_lambads_as_listeners_in_Kotlin.html)

The Ins and Outs of Generic Variance in Kotlin (https://typealias.com/guides/ins-and-outs-of-generic-variance/)

MockK – mocking library for kotlin [https://mockk.io/]

Posted on

Java feature

  1. double brace
  2. ThreadLocal
  3. Instance Initializers
    public class Foo {
      public Foo() {
        System.out.println("constructor called");
      }
     
      static {
        System.out.println("static initializer called");
      }
     
      {
        System.out.println("instance initializer called");
      }
    }
    
  4. Enum – is a class
  5. try, finally, exception
    public static int f() {
        try {
          throw new RuntimeException();
        } finally {
          return 0;
        }
      }
    
  6. URL
    new URL("http://www.yahoo.com").equals(new URL("http://209.191.93.52"))
    

    =true

Posted on

Kotlin by Antonio Leiva

site

12 reasons why you should start using Kotlin for Android today (KAD 30)

How to use Kotlin code from Java: start using Kotlin today (KAD 29)

Sealed classes in Kotlin: enums with super-powers (KAD 28)

Objects in Kotlin: Create safe singletons in one line of code (KAD 27)

Interfaces in Kotlin. Who said interfaces can’t have code? (KAD 26)

Databases on Android with Anko and Kotlin: SQLite never was so easy (KAD 25)

Dialogs and alerts on Android using Anko and Kotlin (KAD 24)

How to mock final classes on Kotlin using Mockito 2 (KAD 23)

Unit tests on Android with Kotlin (KAD 22)

How to use Retrofit on android with Kotlin (KAD 21)

How to use Dagger 2 on Android with Kotlin (KAD 20)

How lambdas work in Kotlin. setOnClickListener transformation (KAD 18)

Operator Overload in Kotlin: Add standard operations to any class (KAD 17)

Writing a RecyclerView Adapter in Kotlin (KAD 16)

Property delegation in Kotlin: Assign values in Android without having the context (KAD 15)

Reified Types in Kotlin: how to use the type within a function (KAD 14)

Using “when” expression in Kotlin: The “switch” with super powers (KAD 13)

Ninja Functions in Kotlin. Understanding the power of generics (KAD 12)

Functional operations with collections in Kotlin (KAD 11)

Data Classes in Kotlin: save a good bunch of lines of code (KAD 10)

Using Anko to run background tasks with Kotlin in Android (KAD 09) + Anko layouts on Android. Should I forget about XMLs?

Custom Views in Android with Kotlin (KAD 06)

Kotlin Android Extensions: Say goodbye to findViewById (KAD 04)

read more on website