- The concise nature drastically reduces the amount of boilerplate code we need to write
- Safe, because, it avoids entire classes of errors such as null pointer exceptions
- Versatile enough to develop server-side applications, Android apps or front end code running in the browser
- The Interoperability helps to leverage existing frameworks and libraries of the JVM with 100% java interoperability.
Steps to setup Kotlin using Android Studio
Android Studio uses Gradle as its build system and part of the effort involved in supporting this environment was adding Gradle support for Kotlin. This tutorial is based on Android Studio 1.2.2 and Kotlin Plugin 0.12.613
1. Install Kotlin plugin and restart Android Studio
Browse for Kotlin and Install plugins
2. Create an Android Studio Project
3. Open MainActivity
4. Rename java directory to Kotlin
5. Convert java Activity file to Kotlin
6. Configure Kotlin in Project
Select Kotlin plugin version and press OK
Gradle file will update with Kotlin
7. Compile and Run the Project… You are done…!
- More About Kotlin – here
- Overview of Kotlin for Android by Jake Wharton – here
- Kotlin Reference – here
- Getting started with Kotlin in 2 minutes – here
go site Need help?
We are Perfomatix. We specialize in building highly scalable APIs and Mobile apps and we also have strong expertise in IoT apps, Virtual Reality apps, and Augmented Reality apps. Get in touch with us to find out how we can help in shaping your disruptive idea into a prototype, MVP and finally into a killer product. Visit our success stories section to find out more about some of the startups which made it big for us.