.. _module-splice-expiry-80141: Splice.Expiry ============= Functions for computing amulet and lock expiry times and conditions\. Data Types ---------- .. _type-splice-expiry-boundedset-6748: **data** `BoundedSet `_ a A symbolic representation of a set of values of type ``a`` useful for computing upper\-bounds\. .. _constr-splice-expiry-singleton-7610: `Singleton `_ a ``Singleton x`` represents the singleton set ``{x}`` .. _constr-splice-expiry-aftermaxbound-46101: `AfterMaxBound `_ ``AfterMaxBound`` represents the set of all values larger than the maximal value that can be represented by type ``a`` **instance** `Functor `_ `BoundedSet `_ **instance** `Eq `_ a \=\> `Eq `_ (`BoundedSet `_ a) **instance** `Show `_ a \=\> `Show `_ (`BoundedSet `_ a) .. _type-splice-expiry-timelock-2221: **data** `TimeLock `_ A lock held by multiple parties until its expiry\. .. _constr-splice-expiry-timelock-44256: `TimeLock `_ .. list-table:: :widths: 15 10 30 :header-rows: 1 * - Field - Type - Description * - holders - \[`Party `_\] - * - expiresAt - `Time `_ - * - optContext - `Optional `_ `Text `_ - Short, human\-readable description of the context in which the amulet is locked\. Intended for wallets to inform the user about the reason for the lock\. Consider what details to share about the context, as that might be private and the string here will be public information\. **instance** :ref:`FromAnyValue ` `TimeLock `_ **instance** :ref:`ToAnyValue ` `TimeLock `_ **instance** `Eq `_ `TimeLock `_ **instance** `Ord `_ `TimeLock `_ **instance** `Show `_ `TimeLock `_ **instance** `GetField `_ \"expiresAt\" `TimeLock `_ `Time `_ **instance** `GetField `_ \"holders\" `TimeLock `_ \[`Party `_\] **instance** `GetField `_ \"lock\" :ref:`LockedAmulet ` `TimeLock `_ **instance** `GetField `_ \"lock\" :ref:`PreprocessedTransferOutput ` (`Optional `_ `TimeLock `_) **instance** `GetField `_ \"lock\" :ref:`TransferOutput ` (`Optional `_ `TimeLock `_) **instance** `GetField `_ \"optContext\" `TimeLock `_ (`Optional `_ `Text `_) **instance** `SetField `_ \"expiresAt\" `TimeLock `_ `Time `_ **instance** `SetField `_ \"holders\" `TimeLock `_ \[`Party `_\] **instance** `SetField `_ \"lock\" :ref:`LockedAmulet ` `TimeLock `_ **instance** `SetField `_ \"lock\" :ref:`PreprocessedTransferOutput ` (`Optional `_ `TimeLock `_) **instance** `SetField `_ \"lock\" :ref:`TransferOutput ` (`Optional `_ `TimeLock `_) **instance** `SetField `_ \"optContext\" `TimeLock `_ (`Optional `_ `Text `_) Functions --------- .. _function-splice-expiry-maxint-28108: `maxInt `_ \: `Int `_ .. _function-splice-expiry-maxdecimaldiv10-64031: `maxDecimalDiv10 `_ \: `Decimal `_ .. _function-splice-expiry-mintime-10075: `minTime `_ \: `Time `_ The smallest time point that can be represented by the ``Time`` type\. .. _function-splice-expiry-maxtime-17293: `maxTime `_ \: `Time `_ The largest time point that can be represented by the ``Time`` type\. .. _function-splice-expiry-amountexpiresat-59287: `amountExpiresAt `_ \: :ref:`ExpiringAmount ` \-\> `BoundedSet `_ :ref:`Round ` Compute the round where the amulet expires\. i\.e\. the amulet is fully expired\. .. _function-splice-expiry-estimateopenroundcreatedat-6216: `estimateOpenRoundCreatedAt `_ \: `RelTime `_ \-\> :ref:`OpenMiningRound ` \-\> `BoundedSet `_ :ref:`Round ` \-\> `BoundedSet `_ `Time `_ ``estimateOpenRoundCreatedAt tickDuration currentMiningRound targetRound`` estimates creation ``Time`` of a specified ``targetRound``\. .. _function-splice-expiry-doeslockexpirebeforeamulet-44609: `doesLockExpireBeforeAmulet `_ \: :ref:`OpenMiningRound ` \-\> `TimeLock `_ \-\> :ref:`ExpiringAmount ` \-\> `RelTime `_ \-\> `Bool `_ ``doesLockExpireBeforeAmulet`` computes whether a ``TimeLock`` expires before a ``Amulet`` .. _function-splice-expiry-isamuletexpired-66613: `isAmuletExpired `_ \: :ref:`OpenMiningRound ` \-\> :ref:`ExpiringAmount ` \-\> `Bool `_ ``isAmuletExpired openRound amuletAmount`` computes whether the expiring ``amuletAmount`` is definitely expired in case the ``openRound`` is open\.