When using Parse’s SDK in Android we generally create a subclass of ParseObject to represent each ‘table’.

To access or change the properties of fetched objects we have to define getters and setters methods:

Just by doing this for each ‘column’ (property) we end with a lot of boilerplate code.

Fortunately, due to Kotlin’s flexibility we can use Delegated Properties and save us a lot of boring code.

By using this custom delegate:

We can ‘delegate’ our setters and getters like this:

Less is more, right? :)

Let me know watch you think in the comments.

Thanks for reading!