Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateLiquidityTier ¶
func GenerateLiquidityTier(optionalModifications ...LtModifierOption) *perptypes.LiquidityTier
GenerateLiquidityTier returns a `LiquidityTier` object set to default values. Passing in `LtModifierOption` methods alters the value of the `LiquidityTier` returned. It will start with the default, valid `LiquidityTier` value defined within the method and make the requested modifications before returning the object.
Example usage: `GenerateLiquidityTier(WithId(7))` This will start with the default `LiquidityTier` object defined within the method and return the newly-created object after overriding the values of `Id` to 7.
Types ¶
type LtModifierOption ¶
type LtModifierOption func(cp *perptypes.LiquidityTier)
func WithId ¶
func WithId(id uint32) LtModifierOption
func WithImpactNotional ¶
func WithImpactNotional(impactNotional uint64) LtModifierOption
func WithInitialMarginPpm ¶
func WithInitialMarginPpm(initialMarginPpm uint32) LtModifierOption
func WithMaintenanceFractionPpm ¶
func WithMaintenanceFractionPpm(maintenanceFractionPpm uint32) LtModifierOption
func WithName ¶
func WithName(name string) LtModifierOption
Click to show internal directories.
Click to hide internal directories.