Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@AlexeySoshin
Created October 22, 2017 16:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AlexeySoshin/8553c2ca0e4443ed121df738728176d4 to your computer and use it in GitHub Desktop.
Save AlexeySoshin/8553c2ca0e4443ed121df738728176d4 to your computer and use it in GitHub Desktop.
// No need for setters getters for a simple POJO
data class Cat(var id : UUID? = null,
val name: String,
val age: Float,
val weight: Float,
var sex : Cat.Sex = Sex.Unknown) {
enum class Sex {
Unknown,
Male,
Female,
NonBinary
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment