def land.gate

cswap-bend-cli@0.1.0.0 · policy/pick.bend:89

import cswap-bend-cli@0.1.0.0/policy/pick.bend as Pick
import Base
import cswap-bend-cli@0.1.0.0/policy/types.bend as T

89def land.gate(+t: T.Trigger, +h: Nat, +thr: Nat) -> Bool:
90  match t:
91    case T.AtLimit{}:
92      True{}
93    case T.Failover{}:
94      True{}
95    case o:
96      Nat.is_ge(h, Nat.add(Nat.sub(T.full(), thr), 1n))

Uses (7)

Used by (1)