|
-
arg0
:
State<'S, ('T -> 'U)>
-
arg1
:
State<'S, 'T>
-
Returns:
State<'S, 'U>
|
|
-
f
:
'T -> State<'S, 'U>
-
arg1
:
State<'S, 'T>
-
Returns:
State<'S, 'U>
|
|
Evaluates a state computation with the initial value and return only the result value of the computation. Ignore the final state.
-
arg0
:
State<'s, 'T>
-
s
:
's
-
Returns:
'T
|
|
Evaluates a state computation with the initial value and return only the final state of the computation. Ignore the result value.
-
arg0
:
State<'S, 'A>
-
s
:
'S
-
Returns:
'S
|
|
Return the state from the internals of the monad.
-
Returns:
State<'S, 'S>
|
|
Get a value which depends on the current state.
-
f
:
'S -> 'T
-
Returns:
State<'S, 'T>
|
|
-
f
:
'T -> 'U
-
arg1
:
State<'S, 'T>
-
Returns:
State<'S, 'U>
|
|
Combines two States into one by applying a mapping function.
-
f
:
'T -> 'U -> 'V
-
arg1
:
State<'S, 'T>
-
arg2
:
State<'S, 'U>
-
Returns:
State<'S, 'V>
|
|
Combines three States into one by applying a mapping function.
-
f
:
'T -> 'U -> 'V -> 'W
-
arg1
:
State<'S, 'T>
-
arg2
:
State<'S, 'U>
-
arg3
:
State<'S, 'V>
-
Returns:
State<'S, 'W>
|
|
Modify the state inside the monad by applying a function.
-
f
:
'S -> 'S
-
Returns:
State<'S, unit>
|
|
Replace the state inside the monad.
-
x
:
'S
-
Returns:
State<'S, unit>
|
|
Runs the state with an inital state to get back the result and the new state.
-
arg0
:
State<'S, 'T>
-
Returns:
'S -> 'T * 'S
|
|
Zips two States into one.
-
x
:
State<'S, 'T>
-
y
:
State<'S, 'U>
-
Returns:
State<'S, ('T * 'U)>
|