Also, if you’re writing a custom data class, you’d need to write code to support immutability which this article’s approach handles