Splice.Schedule
Data Types
data Schedule t a
A schedule of values that change over time.
Field
Type
Description
initialValue
a
Initial value to use until the future values come into effect.
futureValues
[(t, a)]
sorted in ascending order
instance (Eq a, Eq t) => Eq (Schedule t a)
instance (Show a, Show t) => Show (Schedule t a)
instance GetField "configSchedule" AmuletRules (Schedule Time (AmuletConfig USD))
instance GetField "futureValues" (Schedule t a) [(t, a)]
instance GetField "initialValue" (Schedule t a) a
instance GetField "issuanceCurve" (AmuletConfig unit) (Schedule RelTime IssuanceConfig)
instance SetField "configSchedule" AmuletRules (Schedule Time (AmuletConfig USD))
instance SetField "futureValues" (Schedule t a) [(t, a)]
instance SetField "initialValue" (Schedule t a) a
instance SetField "issuanceCurve" (AmuletConfig unit) (Schedule RelTime IssuanceConfig)
Functions
- getValueAsOf
: Ord t => t -> Schedule t a -> a
Get the value as of a specific time
- validSchedule
: Ord t => Schedule t a -> (a -> Bool) -> Bool
Check the validity of a schedule given a function to check the validity of its values
- splitAtTime
: Ord t => [(t, a)] -> t -> ([(t, a)], Optional (t, a), [(t, a)])