Home » Tag Archives: Kotlin

Tag Archives: Kotlin

Improved Pattern Matching in Kotlin

Kotlin doesn’t have true pattern matching, and that’s fine. In order to make matchable classes in Scala, there is an awful lot of overhead required to make it work, and I highly respect Kotlin’s goal of not adding much overhead anywhere. But that doesn’t mean we can’t try to make our own way to get something closer to pattern matching. ...

Read More »

Building and testing a parser with ANTLR and Kotlin

This post is part of a series on how to create a useful language and all the supporting tools. Building a lexer Code Code is available on GitHub. The code described in this post is associated to the tag 02_parser       The parser The parser is simply defined as an ANTLR grammar. We have previously built a separate lexer. ...

Read More »

libgdx and Kotlin – Classes [2D Platformer Prototyping]

This post is a follow up of the libgdx and Kotlin post. I have decided to prototype a simple 2D platformer (along the lines of Star Assault from my early posts), but instead of Java, I am using and learning Kotlin along the way. For this tutorial, the project should be in its initial state from the previous post. A ...

Read More »

Using libGDX with Kotlin

I’ve been reading lately about different languages and what they can bring to the already crowded table of software developers, and one language stood out for me: Kotlin. (https://kotlinlang.org/) It’s a relatively new language (est. 2011) and these are just a few reasons why I picked it over the multitude of other more mature languages: Runs on the JVM and ...

Read More »

Mimicking Kotlin Builders in Java and Python

Intro Kotlin is probably my favorite language right now, and possibly one of the coolest things it has to offer is type-safe builders, built upon several features (explained in a bit). I find myself really really wanting to have this feature in my other two primary languages, Java and Python. This article explains what I believe to be the closest ...

Read More »

Kotlin for Android Developers

We Android Developers have a difficult situation regarding our language limitation. As you may know, current Android development only support Java 6 (with some small improvements from Java 7), so we need to deal every day with a really old language that cuts our productivity and forces us to write tons of boilerplate and fragile code that it’s difficult to ...

Read More »

New Releases with a Better Kotlin API, Dataflow for Clojure and Faster Web Actors

Today we have released minor updates to Quasar, Pulsar and Comsat. The releases contain bug fixes, and some new features including an improved Kotlin API, dataflow variables for Clojure and fast implementations of Web Actors on top of Undertow and Netty. Elegant fibers and channel selection with Kotlin Quasar 0.7.0 introduced a natural Kotlin API (that feels like Erlang) for Quasar ...

Read More »

Flag Parameters and Overloading in Python, Java, and Kotlin

Jumping around between multiple languages can help you notice some differences between idioms and best practices in different languages. One of the more interesting differences has to do with one function doing multiple things. Python We’ll look at Python first. Python is actually incapable of overloading, since defining a new function/method with the same name would just overwrite the previous ...

Read More »

Want to take your Java skills to the next level?

Grab our programming books for FREE!

Here are some of the eBooks you will get:

  • Spring Interview QnA
  • Multithreading & Concurrency QnA
  • JPA Minibook
  • JVM Troubleshooting Guide
  • Advanced Java
  • Java Interview QnA
  • Java Design Patterns