-
Notifications
You must be signed in to change notification settings - Fork 2
/
IVOT3.sol
179 lines (103 loc) Β· 5.13 KB
/
IVOT3.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
// SPDX-License-Identifier: MIT
pragma solidity 0.8.20;
interface IVOT3 {
error AccessControlBadConfirmation();
error AccessControlUnauthorizedAccount(address account, bytes32 neededRole);
error CheckpointUnorderedInsertion();
error ECDSAInvalidSignature();
error ECDSAInvalidSignatureLength(uint256 length);
error ECDSAInvalidSignatureS(bytes32 s);
error ERC20ExceededSafeSupply(uint256 increasedSupply, uint256 cap);
error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);
error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);
error ERC20InvalidApprover(address approver);
error ERC20InvalidReceiver(address receiver);
error ERC20InvalidSender(address sender);
error ERC20InvalidSpender(address spender);
error ERC2612ExpiredSignature(uint256 deadline);
error ERC2612InvalidSigner(address signer, address owner);
error ERC5805FutureLookup(uint256 timepoint, uint48 clock);
error ERC6372InconsistentClock();
error EnforcedPause();
error ExpectedPause();
error InvalidAccountNonce(address account, uint256 currentNonce);
error InvalidShortString();
error SafeCastOverflowedUintDowncast(uint8 bits, uint256 value);
error StringTooLong(string str);
error VotesExpiredSignature(uint256 expiry);
event Approval(address indexed owner, address indexed spender, uint256 value);
event DelegateChanged(address indexed delegator, address indexed fromDelegate, address indexed toDelegate);
event DelegateVotesChanged(address indexed delegate, uint256 previousVotes, uint256 newVotes);
event EIP712DomainChanged();
event Paused(address account);
event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);
event Transfer(address indexed from, address indexed to, uint256 value);
event Unpaused(address account);
function CLOCK_MODE() external view returns (string memory);
function DEFAULT_ADMIN_ROLE() external view returns (bytes32);
function DOMAIN_SEPARATOR() external view returns (bytes32);
function allowance(address owner, address spender) external view returns (uint256);
function approve(address spender, uint256 value) external returns (bool);
function b3tr() external view returns (address);
function balanceOf(address account) external view returns (uint256);
function checkpoints(address account, uint32 pos) external view returns (Checkpoints.Checkpoint208 memory);
function clock() external view returns (uint48);
function decimals() external view returns (uint8);
function delegate(address delegatee) external;
function delegateBySig(address delegatee, uint256 nonce, uint256 expiry, uint8 v, bytes32 r, bytes32 s) external;
function delegates(address account) external view returns (address);
function eip712Domain()
external
view
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
);
function getPastTotalSupply(uint256 timepoint) external view returns (uint256);
function getPastVotes(address account, uint256 timepoint) external view returns (uint256);
function getRoleAdmin(bytes32 role) external view returns (bytes32);
function getVotes(address account) external view returns (uint256);
function grantRole(bytes32 role, address account) external;
function hasRole(bytes32 role, address account) external view returns (bool);
function name() external view returns (string memory);
function nonces(address owner) external view returns (uint256);
function numCheckpoints(address account) external view returns (uint32);
function pause() external;
function paused() external view returns (bool);
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
function renounceRole(bytes32 role, address callerConfirmation) external;
function revokeRole(bytes32 role, address account) external;
function convertToVOT3(uint256 amount) external;
function convertedB3trOf(address account) external view returns (uint256);
function supportsInterface(bytes4 interfaceId) external view returns (bool);
function symbol() external view returns (string memory);
function totalSupply() external view returns (uint256);
function transfer(address to, uint256 value) external returns (bool);
function transferFrom(address from, address to, uint256 value) external returns (bool);
function unpause() external;
function convertToB3TR(uint256 amount) external;
function getQuadraticVotingPower(address account) external view returns (uint256);
function getPastQuadraticVotingPower(address account, uint256 timepoint) external view returns (uint256);
function version() external view returns (string memory);
}
interface Checkpoints {
struct Checkpoint208 {
uint48 _key;
uint208 _value;
}
}