Functions
Last updated
Last updated
Trading
deposit-funds
The function transfers the underlying amount from the depositor
to the vault contract.
payout-funds
The function pays out the underlying amount to the recipient
. The function is called by the comptroller
contract as part of the logic for confirm-trade
.
Intra-epoch
queue-deposit
The function transfers the underlying amount to the vault contract and creates a claim for the deposited amount in the claims
map.
The function transfers the token amount to the vault contract and creates a claim for the token amount in the claims
map.
The function transfers the total underlying and token amount of all outstanding claims to the address.
The function transfers the total underlying and token amount of all outstanding claims for each address in the addresses list.
Settlement
The function returns the current price of one token.
The function creates a new entry in the epoch-info-for-claims
map and adds 1 to the current-epoch-id
variable.
The function writes the current underlying-per-token
value to the epoch-info-for-claims
map.
Claim Activation
The function updates the tokens-reserved-for-claims
variable and resets total-pending-deposits
.
The function updates the underlying-reserved-for-claims
variable, burns the tokens queue for withdrawal which implicitly resets total-pending-withdrawals
.
queue-withdrawal
claim
claim-many
get-underlying-per-token
create-epoch-info-for-claims
update-epoch-info-for-claims
activate-pending-deposit-claims
activate-pending-withdrawal-claims