Documentation ¶
Index ¶
- func ToTuple[T any](result Result[T]) (T, error)
- type Result
- func (result Result[T]) AssertErr()
- func (result Result[T]) AssertOk()
- func (result Result[T]) IsErr() bool
- func (result Result[T]) IsOk() bool
- func (result Result[T]) Match(okHandler func(T), errHandler func(error))
- func (result Result[T]) MustGetErr() error
- func (result Result[T]) MustGetOk() T
- func (result Result[T]) ToEither() choice.Choice[T, error]
- func (result Result[T]) Try(f func() (T, error)) Result[T]
- func (result Result[T]) TryT(f func() (T, error)) Result[T]
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Result ¶
type Result[T any] struct { // contains filtered or unexported fields }
func (Result[T]) MustGetErr ¶
Click to show internal directories.
Click to hide internal directories.