Skip to content

Instantly share code, notes, and snippets.

@hadilq
Created January 10, 2021 23:01
Show Gist options
  • Save hadilq/ec51a8450d4a0b798e5694d5262449a7 to your computer and use it in GitHub Desktop.
Save hadilq/ec51a8450d4a0b798e5694d5262449a7 to your computer and use it in GitHub Desktop.
The result of send method
sealed class SendResult
data class SendSuccess(val email: Email): SendResult()
data class IOFailure(val error: IOException): SendResult()
data class Timeout(val error: TimeoutException): SendResult()
data class UnAuthorized(val error: UnAuthorizedException): SendResult()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment