Swivel
Annotated source of the Swivel.sol smart contract
constructor
Parameters:
initiate
Allows a user to initiate a position
Parameters:
initiateVaultFillingZcTokenInitiate
Allows a user to initiate a Vault by filling an offline zcToken initiate order
This method should pass (underlying, maturity, maker, sender, principalFilled) to MarketPlace.custodialInitiate
Parameters:
initiateZcTokenFillingVaultInitiate
Allows a user to initiate a zcToken by filling an offline vault initiate order
This method should pass (underlying, maturity, sender, maker, a) to MarketPlace.custodialInitiate
Parameters:
initiateZcTokenFillingZcTokenExit
Allows a user to initiate zcToken? by filling an offline zcToken exit order
This method should pass (underlying, maturity, maker, sender, a) to MarketPlace.p2pZcTokenExchange
Parameters:
initiateVaultFillingVaultExit
Allows a user to initiate a Vault by filling an offline vault exit order
This method should pass (underlying, maturity, maker, sender, principalFilled) to MarketPlace.p2pVaultExchange
Parameters:
exit
Allows a user to exit (sell) a currently held position to the marketplace.
Parameters:
exitZcTokenFillingZcTokenInitiate
Allows a user to exit their zcTokens by filling an offline zcToken initiate order
This method should pass (underlying, maturity, sender, maker, principalFilled) to MarketPlace.p2pZcTokenExchange
Parameters:
exitVaultFillingVaultInitiate
Allows a user to exit their Vault by filling an offline vault initiate order
This method should pass (underlying, maturity, sender, maker, a) to MarketPlace.p2pVaultExchange
Parameters:
exitVaultFillingZcTokenExit
Allows a user to exit their Vault filling an offline zcToken exit order
This method should pass (underlying, maturity, maker, sender, a) to MarketPlace.exitFillingExit
Parameters:
exitZcTokenFillingVaultExit
Allows a user to exit their zcTokens by filling an offline vault exit order
This method should pass (underlying, maturity, sender, maker, principalFilled) to MarketPlace.exitFillingExit
Parameters:
cancel
Allows a user to cancel an order, preventing it from being filled in the future
Parameters:
transferAdmin
Parameters:
scheduleWithdrawal
Allows the admin to schedule the withdrawal of tokens
Parameters:
blockWithdrawal
Emergency function to block unplanned withdrawals
Parameters:
withdraw
Allows the admin to withdraw the given token, provided the holding period has been observed
Parameters:
setFee
Allows the admin to set a new fee denominator
Parameters:
approveUnderlying
Allows the admin to bulk approve given compound addresses at the underlying token, saving marginal approvals
Parameters:
splitUnderlying
Allows users to deposit underlying and in the process split it into/mint zcTokens and vault notional. Calls mPlace.mintZcTokenAddingNotional
Parameters:
combineTokens
Allows users deposit/burn 1-1 amounts of both zcTokens and vault notional, in the process "combining" the two, and redeeming underlying. Calls mPlace.burnZcTokenRemovingNotional.
Parameters:
redeemZcToken
Allows zcToken holders to redeem their tokens for underlying tokens after maturity has been reached (via MarketPlace).
Parameters:
redeemVaultInterest
Allows Vault owners to redeem any currently accrued interest (via MarketPlace)
Parameters:
validOrderHash
Varifies the validity of an order and it's signature.
Parameters:
Return Values:
Initiate
Emitted on any initiate*
filled is 'principalFilled' when (vault:false, exit:false) && (vault:true, exit:true) filled is 'premiumFilled' when (vault:true, exit:false) && (vault:false, exit:true)
Exit
Emitted on any exit*
filled is 'principalFilled' when (vault:false, exit:false) && (vault:true, exit:true) filled is 'premiumFilled' when (vault:true, exit:false) && (vault:false, exit:true)
ScheduleWithdrawal
Emitted on token withdrawal scheduling
BlockWithdrawal
Emitted on token withdrawal blocking
SetFee
Emitted on a change to the feenominators array
Last updated