Skip to content

Instantly share code, notes, and snippets.

@hadilq
Created January 10, 2021 23:00
Show Gist options
  • Save hadilq/547cc079c35976207850e754a25db77d to your computer and use it in GitHub Desktop.
Save hadilq/547cc079c35976207850e754a25db77d to your computer and use it in GitHub Desktop.
sealed class Result<T>
data class Success<T>(val value: T): Result<T>()
data class Failure<T>(val errorMessage: String): Result<T>()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment