Learning Kotlin
The Utilihive SDK is designed to be used in a Kotlin project, but you do not need to be a Kotlin expert to start developing flows. Flows themselves are written in a Lowcode DSL, after all. Most of the Kotlin logic you implement will actually be part of your unit and functional tests. Of course, the more Kotlin you know, the better! If you are new to the Kotlin programming language, there are a few courses you can take directly in IntelliJ.
JetBrains Academy Plugin
To access the Kotlin courses, you will need to install the JetBrains Academy plugin for IntelliJ. The following steps outline how to do this from the IntelliJ editor:
-
Select File > Settings on Windows and Linux or IntelliJ IDEA > Settings on macOS.
-
In the Settings window, select Plugins.
-
In the Marketplace tab, search for "jetbrains academy".
-
Select the Install button to install the JetBrains Academy plugin.
The process will look like the following image:
After JetBrains Academy is set up, you can then install Greenbird’s "Kotlin for Flow Developers" course and/or the Kotlin team’s own "Kotlin Koans" exercises.
Kotlin for Flow Developers
The Kotlin for Flow Developers course is a series of code examples and exercises that serve as an introduction to the Kotlin programming language. Specifically, it focuses only on the essentials needed to write and test flows with the Utilihive SDK.
The installation process is as follows:
-
Download the Kotlin_for_Flow_Developers.zip archive.
-
In IntelliJ, select File > Learn and Teach > Browse Courses.
-
Select "My Courses" on the left.
-
Select "Open course from disk".
-
Navigate to the zip file and open it.
The process will look like the following image:
If you already have one or more courses installed, the "Open course from disk" option will appear at the bottom of the window. |
For best results, you will want to change the JDK that the course uses to Java 17, which you should already have from the SDK installation guide. The following image highlights where the JDK can be changed from the course introduction window:
Kotlin Koans
The Kotlin Koans are a series of exercises presented as failing unit tests. They make for a great next step after completing the Kotlin for Flow Developers course, especially if you want to dive deeper into Kotlin syntax and its features.
To install the Koans, follow these steps:
-
In IntelliJ, select File > Learn and Teach > Browse Courses.
-
In the Marketplace tab, scroll down to Kotlin Koans.
-
Select the Start button on the right.
The process will look like the following image:
Also check out the official Kotlin documentation and the Kotlin Core track from the JetBrains Academy team for more Kotlin help.