Media Player basics for Android

As my previous post about creating Android Music Player was getting a lot of traction, I figured it's about time to do a rewrite as the previous one is ages old and there have been a lot of improvements and better APIs on Android for supporting music since then. This…

Building a Music Player App for Android

As my previous post about creating Android Music Player was getting a lot of traction, I figured it's about time to do a rewrite as the previous one is ages old and there have been a lot of improvements and better APIs on Android for supporting music since then. This…

Why I use Kotlin for Android

Kotlin is a statically typed language developed by JetBrains that targets the JVM. If you have worked with Java before, you know how verbose it could be. When Apple released Swift, developers rejoiced for a better alternative to Objective C. Kotlin could be that alternative for Android developers working with…

Refresh OAuth access token with Retrofit, RxJava

A very common use case when working with OAuth is to refresh the auth token. One way could be to do it periodically. A much simpler way, although, is to try refresh the auth token when you see a 401 response for an authenticated user. This is very straightforward to…

Refresh OAuth tokens using Moya, RxSwift

A very common use case when working with OAuth is to refresh the auth token. One way could be to do it periodically. A much simpler way, although, is to try refresh the auth token when you see a 401 response for an authenticated user. This is very straightforward to…

Realm for Android

Realm is a mobile database: a replacement for SQLite & Core Data that works for both iOS and Android. It has a really concise API and works extremely fast. Let's see how we define a model in Realm: public class User extends RealmObject { @PrimaryKey private int identifier; private String firstName;…