vBase
ERC20 token traded on the CryptoSwap pool
Methods
DEFAULT_ADMIN_ROLE
Returns
EMERGENCY_ADMIN
Returns
GOVERNANCE
Returns
aggregator
Returns
allowance
Parameters
Returns
approve
Sets amount
as the allowance of spender
over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.
Parameters
Returns
balanceOf
Parameters
Returns
burn
Parameters
decimals
Returns
getIndexPrice
Returns
getRoleAdmin
Returns the admin role that controls role
. See {grantRole} and {revokeRole}. To change a role's admin, use {_setRoleAdmin}.
Parameters
Returns
gracePeriod
Returns
grantRole
Grants role
to account
. If account
had not been already granted role
, emits a {RoleGranted} event. Requirements: - the caller must have role
's admin role. May emit a {RoleGranted} event.
Parameters
hasRole
Returns true
if account
has been granted role
.
Parameters
Returns
heartBeat
Returns
isEmergencyAdmin
Parameters
Returns
isGovernor
Parameters
Returns
mint
Parameters
name
Returns
perp
Returns
renounceRole
Revokes role
from the calling account. Roles are often managed via {grantRole} and {revokeRole}: this function's purpose is to provide a mechanism for accounts to lose their privileges if they are compromised (such as when a trusted device is misplaced). If the calling account had been revoked role
, emits a {RoleRevoked} event. Requirements: - the caller must be account
. May emit a {RoleRevoked} event.
Parameters
revokeRole
Revokes role
from account
. If account
had been granted role
, emits a {RoleRevoked} event. Requirements: - the caller must have role
's admin role. May emit a {RoleRevoked} event.
Parameters
sequencerUptimeFeed
Returns
setGracePeriod
Parameters
setHeartBeat
Parameters
setSequencerUptimeFeed
Parameters
supportsInterface
See {IERC165-supportsInterface}.
Parameters
Returns
symbol
Returns
totalSupply
Returns
transfer
Moves amount
tokens from the caller's account to to
. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.
Parameters
Returns
transferFrom
Moves amount
tokens from from
to to
using the allowance mechanism. amount
is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.
Parameters
Returns
transferPerpOwner
Transfer perp
accountCan only be used at deployment as Perpetual can't transfer ownership afterwards
Parameters
Events
Approval
Parameters
GracePeriodUpdated
Emitted when grace period is updated
Parameters
HeartBeatUpdated
Emitted when oracle heart beat is updated
Parameters
PerpOwnerTransferred
Parameters
RoleAdminChanged
Parameters
RoleGranted
Parameters
RoleRevoked
Parameters
SequencerUptimeFeedUpdated
Emitted when sequencer uptime feed is updated
Parameters
Transfer
Parameters
Errors
PerpOwnable_NotOwner
Emitted when the sender is not perp
PerpOwnable_TransferZeroAddress
Emitted when the proposed address is equal to the zero address
VBase_DataNotFresh
Emitted when the latest round's data is older than the oracle's max refresh time
VBase_GracePeriodNotOver
Emitted when Zksync sequencer hasn't been back up for long enough
VBase_IncorrectGracePeriod
Emitted when proposed grace period is outside of the bounds
VBase_IncorrectHeartBeat
Emitted when the proposed heart beat is less than 1 sec second
VBase_InsufficientPrecision
Emitted when the proposed aggregators decimals are less than PRECISION
VBase_InvalidRoundPrice
Emitted when the latest round's price is invalid
VBase_InvalidRoundTimestamp
Emitted when the latest round is incomplete
VBase_SequencerDown
Emitted when Zksync sequencer is down
VBase_SequencerUptimeFeedZeroAddress
Emitted when proposed sequencer uptime feed address is equal to the zero address
Last updated