Final class FH\IO<+T>
Functions that create, combine, and unsafely execute I/O actions.
Constructor
__construct((function(): T) $action)
- Construct an I/O action which when performed executes the given (potentially effectful) procedure.
Static methods
pure(T $x): IO<T>
- Return an I/O action that has no effects and returns the given value.
Instance methods
unsafePerform(): T
- Perform this I/O action, including any effects it may have.
map<TM>((function(T): TM) $f): IO<TM>
- Return an I/O action that performs this I/O action and transforms its result with the given function.
bind<TM>((function(T): IO<TM>) $f): IO<TM>
- Combine this I/O action with a Kleisli arrow.