Skip to content

Instantly share code, notes, and snippets.

Created March 20, 2022 08:22
What would you like to do?
class Task(
val id: Int,
val description: Description,
val priority: Priority = Normal,
val status: Status = NotStarted,
val attachment: Attachment? = null
) : Parcelable
class Attachment(val path: String) : Parcelable
value class Description(val value: String) : Parcelable
enum class Priority {
sealed class Status : Parcelable {
object NotStarted : Status()
object InProgress : Status()
class Completed(val completedAt: LocalDate) : Status()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment