IVirtualIssuanceSupplyBase_v1.sol
Functions
setVirtualIssuanceSupply
Sets the virtual issuance supply to a new value.
This function calls the internal function _setVirtualIssuanceSupply
. The function must be implemented by the downstream contract. The downstream contract should manage access control for setting the supply.
function setVirtualIssuanceSupply(uint _virtualSupply) external;
Parameters
_virtualSupply
uint256
The new value to set for the virtual issuance supply.
getVirtualIssuanceSupply
Returns the current virtual issuance supply.
This function returns the virtual supply by calling the internal _getVirtualIssuanceSupply
function.
function getVirtualIssuanceSupply() external view returns (uint);
Returns
<none>
uint256
The current virtual issuance supply as a uint.
Events
VirtualIssuanceSupplySet
Event emitted when virtual issuance supply has been set.
event VirtualIssuanceSupplySet(uint newSupply, uint oldSupply);
Parameters
newSupply
uint256
The new virtual issuance supply.
oldSupply
uint256
The old virtual issuance supply.
VirtualIssuanceAmountAdded
Event emitted when virtual issuance amount has been added.
event VirtualIssuanceAmountAdded(uint amountAdded, uint newSupply);
Parameters
amountAdded
uint256
The amount added to the virtual issuance supply.
newSupply
uint256
The new virtual issuance supply.
VirtualIssuanceAmountSubtracted
Event emitted when virtual issuance amount has ben subtracted.
event VirtualIssuanceAmountSubtracted(uint amountSubtracted, uint newSupply);
Parameters
amountSubtracted
uint256
The amount subtracted from the virtual issuance supply.
newSupply
uint256
The new virtual issuance supply.
Errors
Module__VirtualIssuanceSupplyBase__VirtualSupplyCannotBeZero
The virtual supply cannot be zero.
error Module__VirtualIssuanceSupplyBase__VirtualSupplyCannotBeZero();
Module__VirtualIssuanceSupplyBase__SubtractResultsInUnderflow
Subtracting would result in an underflow.
error Module__VirtualIssuanceSupplyBase__SubtractResultsInUnderflow();
Module__VirtualIssuanceSupplyBase__AddResultsInOverflow
Adding would result in and overflow.
error Module__VirtualIssuanceSupplyBase__AddResultsInOverflow();
Last updated