src/core/variable.bend checks
raw source on the hub · import bend-ta@0.1.0.0/src/core/variable.bend as Variable
3 imports
import Base import ./ma.bend as Ma import ./variable_shared.bend as Shared
Types
type Sample source · line 5 · raw
@-N:Data -> Data
Sample@-N:Data -> @price:N -> @period:N -> Sample<N>
type Entry source · line 8 · raw
@-N:Data -> Type
Waiting@-N:Data -> @period:U32 -> @delay:U32 -> Entry<N>
Active@-N:Data -> @period:U32 -> @average:0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N> -> Entry<N>
type State source · line 12 · raw
@-N:Data -> Type
State@-N:Data -> @entries:List<&1, Entry<N>> -> @minimum:U32 -> @maximum:U32 -> @kind:U32 -> State<N>
Buffered@-N:Data -> @state:0xbb55196063fb99add8900a97dfe6ee2d/src/core/variable_shared.State<N> -> @minimum:U32 -> @maximum:U32 -> State<N>
Direct@-N:Data -> State<N>
type Update source · line 17 · raw
@-N:Data -> Type
Update@-N:Data -> @entries:List<&1, Entry<N>> -> @price:N -> @selected:U32 -> @kind:U32 -> @output:Maybe<&2, N> -> Update<N>
Templates
template entries source · line 20 · raw
@-N:Data -> @fuel:Nat -> @+period:U32 -> @+kind:U32 -> @+lookback:U32 -> @acc:List<&1, Entry<N>> -> List<&1, Entry<N>>
template init.mode source · line 25 · raw
@-N:Data -> @+minimum:U32 -> @+maximum:U32 -> @+kind:U32 -> @direct:Bool -> @shared:Bool -> State<N>
template init source · line 31 · raw
@-N:Data -> @+minimum:U32 -> @+maximum:U32 -> @+kind:U32 -> State<N>
template normalize.upper source · line 34 · raw
@-N:Data -> @-to:(@_:N -> U32) -> @minimum:U32 -> @maximum:U32 -> @value:N -> @above:Bool -> U32
template normalize.lower source · line 39 · raw
@-N:Data -> @-from:(@_:U32 -> N) -> @-to:(@_:N -> U32) -> @-gt:(@_:N -> @_:N -> Bool) -> @+minimum:U32 -> @+maximum:U32 -> @+value:N -> @bounded:Bool -> U32
template normalize source · line 44 · raw
@-N:Data -> @-from:(@_:U32 -> N) -> @-to:(@_:N -> U32) -> @-ge:(@_:N -> @_:N -> Bool) -> @-gt:(@_:N -> @_:N -> Bool) -> @+minimum:U32 -> @maximum:U32 -> @+value:N -> U32
template updated source · line 47 · raw
@-N:Data -> @entries:List<&1, Entry<N>> -> @price:N -> @+selected:U32 -> @kind:U32 -> @output:Maybe<&2, N> -> @+period:U32 -> @result:Pair(0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>, Maybe<&2, N>) -> Update<N>
template waiting source · line 51 · raw
@-N:Data -> @-make:(@_:U32 -> @_:U32 -> 0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>) -> @-step:(@_:0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N> -> @_:N -> Pair(0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>, Maybe<&2, N>)) -> @entries:List<&1, Entry<N>> -> @+price:N -> @selected:U32 -> @+kind:U32 -> @output:Maybe<&2, N> -> @+period:U32 -> @delay:Nat -> Update<N>
template update source · line 56 · raw
@-N:Data -> @-make:(@_:U32 -> @_:U32 -> 0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>) -> @-step:(@_:0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N> -> @_:N -> Pair(0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>, Maybe<&2, N>)) -> @state:Update<N> -> @entry:Entry<N> -> Update<N>
template finish source · line 61 · raw
@-N:Data -> @minimum:U32 -> @maximum:U32 -> @result:Update<N> -> Pair(State<N>, Maybe<&2, N>)
template next source · line 69 · raw
@-N:Data -> @-from:(@_:U32 -> N) -> @-to:(@_:N -> U32) -> @-ge:(@_:N -> @_:N -> Bool) -> @-gt:(@_:N -> @_:N -> Bool) -> @-make:(@_:U32 -> @_:U32 -> 0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>) -> @-step:(@_:0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N> -> @_:N -> Pair(0xbb55196063fb99add8900a97dfe6ee2d/src/core/ma.State<N>, Maybe<&2, N>)) -> @-shared:(@_:0xbb55196063fb99add8900a97dfe6ee2d/src/core/variable_shared.State<N> -> @_:N -> @_:U32 -> Pair(0xbb55196063fb99add8900a97dfe6ee2d/src/core/variable_shared.State<N>, Maybe<&2, N>)) -> @state:State<N> -> @sample:Sample<N> -> Pair(State<N>, Maybe<&2, N>)