-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathRightsManager.json
318 lines (318 loc) · 26.6 KB
/
RightsManager.json
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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
{
"address": "0x11D61d0855aCfB43b3C9275b70403EcCC7212536",
"abi": [
{
"inputs": [],
"name": "DEFAULT_CAN_ADD_REMOVE_TOKENS",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_CAN_CHANGE_SWAP_FEE",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_CAN_CHANGE_WEIGHTS",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_CAN_PAUSE_SWAPPING",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_CAN_TOKEN_WHITELISTS",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_CAN_WHITELIST_LPS",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bool[]",
"name": "a",
"type": "bool[]"
}
],
"name": "constructRights",
"outputs": [
{
"components": [
{
"internalType": "bool",
"name": "canPauseSwapping",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeSwapFee",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeWeights",
"type": "bool"
},
{
"internalType": "bool",
"name": "canAddRemoveTokens",
"type": "bool"
},
{
"internalType": "bool",
"name": "canWhitelistLPs",
"type": "bool"
},
{
"internalType": "bool",
"name": "canTokenWhiteLists",
"type": "bool"
}
],
"internalType": "struct RightsManager.Rights",
"name": "",
"type": "tuple"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bool",
"name": "canPauseSwapping",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeSwapFee",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeWeights",
"type": "bool"
},
{
"internalType": "bool",
"name": "canAddRemoveTokens",
"type": "bool"
},
{
"internalType": "bool",
"name": "canWhitelistLPs",
"type": "bool"
},
{
"internalType": "bool",
"name": "canTokenWhiteLists",
"type": "bool"
}
],
"internalType": "struct RightsManager.Rights",
"name": "rights",
"type": "tuple"
}
],
"name": "convertRights",
"outputs": [
{
"internalType": "bool[]",
"name": "",
"type": "bool[]"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bool",
"name": "canPauseSwapping",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeSwapFee",
"type": "bool"
},
{
"internalType": "bool",
"name": "canChangeWeights",
"type": "bool"
},
{
"internalType": "bool",
"name": "canAddRemoveTokens",
"type": "bool"
},
{
"internalType": "bool",
"name": "canWhitelistLPs",
"type": "bool"
},
{
"internalType": "bool",
"name": "canTokenWhiteLists",
"type": "bool"
}
],
"internalType": "struct RightsManager.Rights",
"name": "self",
"type": "tuple"
},
{
"internalType": "enum RightsManager.Permissions",
"name": "permission",
"type": "RightsManager.Permissions"
}
],
"name": "hasPermission",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "pure",
"type": "function"
}
],
"transactionHash": "0xed240eae91b5fd3bfc5a8a561e509ea97951962ee46d60b1342456353092c0ba",
"receipt": {
"to": null,
"from": "0x595b85b4A418e3B8df897D02F5BD49167D00862F",
"contractAddress": "0x11D61d0855aCfB43b3C9275b70403EcCC7212536",
"transactionIndex": 0,
"gasUsed": "414847",
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"blockHash": "0x21610ef7cff965ede68f8e9b169d92506de70fdfe8f60f633acda5a052614ee2",
"transactionHash": "0xed240eae91b5fd3bfc5a8a561e509ea97951962ee46d60b1342456353092c0ba",
"logs": [],
"blockNumber": 8091155,
"cumulativeGasUsed": "414847",
"status": 1,
"byzantium": true
},
"args": [],
"numDeployments": 1,
"solcInputHash": "ad611d3edcdf2b99f8b7701d90abc71c",
"metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"name\":\"DEFAULT_CAN_ADD_REMOVE_TOKENS\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"DEFAULT_CAN_CHANGE_SWAP_FEE\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"DEFAULT_CAN_CHANGE_WEIGHTS\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"DEFAULT_CAN_PAUSE_SWAPPING\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"DEFAULT_CAN_TOKEN_WHITELISTS\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"DEFAULT_CAN_WHITELIST_LPS\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool[]\",\"name\":\"a\",\"type\":\"bool[]\"}],\"name\":\"constructRights\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"canPauseSwapping\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeSwapFee\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeWeights\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canAddRemoveTokens\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canWhitelistLPs\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canTokenWhiteLists\",\"type\":\"bool\"}],\"internalType\":\"struct RightsManager.Rights\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"canPauseSwapping\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeSwapFee\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeWeights\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canAddRemoveTokens\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canWhitelistLPs\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canTokenWhiteLists\",\"type\":\"bool\"}],\"internalType\":\"struct RightsManager.Rights\",\"name\":\"rights\",\"type\":\"tuple\"}],\"name\":\"convertRights\",\"outputs\":[{\"internalType\":\"bool[]\",\"name\":\"\",\"type\":\"bool[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"canPauseSwapping\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeSwapFee\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canChangeWeights\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canAddRemoveTokens\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canWhitelistLPs\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"canTokenWhiteLists\",\"type\":\"bool\"}],\"internalType\":\"struct RightsManager.Rights\",\"name\":\"self\",\"type\":\"tuple\"},{\"internalType\":\"enum RightsManager.Permissions\",\"name\":\"permission\",\"type\":\"RightsManager.Permissions\"}],\"name\":\"hasPermission\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Desyn Labs\",\"kind\":\"dev\",\"methods\":{\"constructRights(bool[])\":{\"details\":\"If you pass an empty array, it will construct it using the defaults\",\"params\":{\"a\":\"- array input\"},\"returns\":{\"_0\":\"Rights struct\"}},\"convertRights(RightsManager.Rights)\":{\"details\":\"avoids multiple calls to hasPermission\",\"params\":{\"rights\":\"- the rights struct to convert\"},\"returns\":{\"_0\":\"boolean array containing the rights settings\"}},\"hasPermission(RightsManager.Rights,RightsManager.Permissions)\":{\"params\":{\"permission\":\"- The permission to check\",\"self\":\"- Rights struct containing the permissions\"},\"returns\":{\"_0\":\"Boolean true if it has the permission\"}}},\"title\":\"Manage Configurable Rights for the smart pool canPauseSwapping - can setPublicSwap back to false after turning it on by default, it is off on initialization and can only be turned on canChangeSwapFee - can setSwapFee after initialization (by default, it is fixed at create time) canChangeWeights - can bind new token weights (allowed by default in base pool) canAddRemoveTokens - can bind/unbind tokens (allowed by default in base pool) canWhitelistLPs - can limit liquidity providers to a given set of addresses canChangeCap - can change the BSP cap (max # of pool tokens) canChangeFloor - can change the BSP floor for Closure ETF (min # of pool tokens)\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"constructRights(bool[])\":{\"notice\":\"create a struct from an array (or return defaults)\"},\"convertRights(RightsManager.Rights)\":{\"notice\":\"Convert rights struct to an array (e.g., for events, GUI)\"},\"hasPermission(RightsManager.Rights,RightsManager.Permissions)\":{\"notice\":\"Externally check permissions using the Enum\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/libraries/RightsManager.sol\":\"RightsManager\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":20},\"remappings\":[]},\"sources\":{\"contracts/libraries/RightsManager.sol\":{\"content\":\"// SPDX-License-Identifier: GPL-3.0-or-later\\npragma solidity 0.6.12;\\n\\n// Needed to handle structures externally\\npragma experimental ABIEncoderV2;\\n\\n/**\\n * @author Desyn Labs\\n * @title Manage Configurable Rights for the smart pool\\n * canPauseSwapping - can setPublicSwap back to false after turning it on\\n * by default, it is off on initialization and can only be turned on\\n * canChangeSwapFee - can setSwapFee after initialization (by default, it is fixed at create time)\\n * canChangeWeights - can bind new token weights (allowed by default in base pool)\\n * canAddRemoveTokens - can bind/unbind tokens (allowed by default in base pool)\\n * canWhitelistLPs - can limit liquidity providers to a given set of addresses\\n * canChangeCap - can change the BSP cap (max # of pool tokens)\\n * canChangeFloor - can change the BSP floor for Closure ETF (min # of pool tokens)\\n */\\nlibrary RightsManager {\\n // Type declarations\\n\\n enum Permissions {\\n PAUSE_SWAPPING,\\n CHANGE_SWAP_FEE,\\n CHANGE_WEIGHTS,\\n ADD_REMOVE_TOKENS,\\n WHITELIST_LPS,\\n TOKEN_WHITELISTS\\n // CHANGE_CAP,\\n // CHANGE_FLOOR\\n }\\n\\n struct Rights {\\n bool canPauseSwapping;\\n bool canChangeSwapFee;\\n bool canChangeWeights;\\n bool canAddRemoveTokens;\\n bool canWhitelistLPs;\\n bool canTokenWhiteLists;\\n // bool canChangeCap;\\n // bool canChangeFloor;\\n }\\n\\n // State variables (can only be constants in a library)\\n bool public constant DEFAULT_CAN_PAUSE_SWAPPING = false;\\n bool public constant DEFAULT_CAN_CHANGE_SWAP_FEE = true;\\n bool public constant DEFAULT_CAN_CHANGE_WEIGHTS = true;\\n bool public constant DEFAULT_CAN_ADD_REMOVE_TOKENS = false;\\n bool public constant DEFAULT_CAN_WHITELIST_LPS = false;\\n bool public constant DEFAULT_CAN_TOKEN_WHITELISTS = false;\\n\\n // bool public constant DEFAULT_CAN_CHANGE_CAP = false;\\n // bool public constant DEFAULT_CAN_CHANGE_FLOOR = false;\\n\\n // Functions\\n\\n /**\\n * @notice create a struct from an array (or return defaults)\\n * @dev If you pass an empty array, it will construct it using the defaults\\n * @param a - array input\\n * @return Rights struct\\n */\\n function constructRights(bool[] calldata a) external pure returns (Rights memory) {\\n if (a.length < 6) {\\n return\\n Rights(\\n DEFAULT_CAN_PAUSE_SWAPPING,\\n DEFAULT_CAN_CHANGE_SWAP_FEE,\\n DEFAULT_CAN_CHANGE_WEIGHTS,\\n DEFAULT_CAN_ADD_REMOVE_TOKENS,\\n DEFAULT_CAN_WHITELIST_LPS,\\n DEFAULT_CAN_TOKEN_WHITELISTS\\n // DEFAULT_CAN_CHANGE_CAP,\\n // DEFAULT_CAN_CHANGE_FLOOR\\n );\\n } else {\\n // return Rights(a[0], a[1], a[2], a[3], a[4], a[5], a[6]);\\n return Rights(a[0], a[1], a[2], a[3], a[4], a[5]);\\n }\\n }\\n\\n /**\\n * @notice Convert rights struct to an array (e.g., for events, GUI)\\n * @dev avoids multiple calls to hasPermission\\n * @param rights - the rights struct to convert\\n * @return boolean array containing the rights settings\\n */\\n function convertRights(Rights calldata rights) external pure returns (bool[] memory) {\\n bool[] memory result = new bool[](6);\\n\\n result[0] = rights.canPauseSwapping;\\n result[1] = rights.canChangeSwapFee;\\n result[2] = rights.canChangeWeights;\\n result[3] = rights.canAddRemoveTokens;\\n result[4] = rights.canWhitelistLPs;\\n result[5] = rights.canTokenWhiteLists;\\n // result[5] = rights.canChangeCap;\\n // result[6] = rights.canChangeFloor;\\n\\n return result;\\n }\\n\\n // Though it is actually simple, the number of branches triggers code-complexity\\n /* solhint-disable code-complexity */\\n\\n /**\\n * @notice Externally check permissions using the Enum\\n * @param self - Rights struct containing the permissions\\n * @param permission - The permission to check\\n * @return Boolean true if it has the permission\\n */\\n function hasPermission(Rights calldata self, Permissions permission) external pure returns (bool) {\\n if (Permissions.PAUSE_SWAPPING == permission) {\\n return self.canPauseSwapping;\\n } else if (Permissions.CHANGE_SWAP_FEE == permission) {\\n return self.canChangeSwapFee;\\n } else if (Permissions.CHANGE_WEIGHTS == permission) {\\n return self.canChangeWeights;\\n } else if (Permissions.ADD_REMOVE_TOKENS == permission) {\\n return self.canAddRemoveTokens;\\n } else if (Permissions.WHITELIST_LPS == permission) {\\n return self.canWhitelistLPs;\\n } else if (Permissions.TOKEN_WHITELISTS == permission) {\\n return self.canTokenWhiteLists;\\n }\\n // else if (Permissions.CHANGE_CAP == permission) {\\n // return self.canChangeCap;\\n // } else if (Permissions.CHANGE_FLOOR == permission) {\\n // return self.canChangeFloor;\\n // }\\n }\\n\\n /* solhint-enable code-complexity */\\n}\\n\",\"keccak256\":\"0x398bbfe72673fa1c42a7d59fb5f7b2a46332887e105bf6fdff234a9a83247d0e\",\"license\":\"GPL-3.0-or-later\"}},\"version\":1}",
"bytecode": "0x61068a610026600b82828239805160001a60731461001957fe5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061008d5760003560e01c806321bb04ae146100925780632cc0c346146100b05780633d027b9d146100b05780634583544a146100b8578063710a51c2146100cb578063c08473fc146100eb578063cb0d28f614610092578063dccf54e7146100b0578063fe7f62d1146100b0575b600080fd5b61009a61010b565b6040516100a791906105f9565b60405180910390f35b61009a610110565b61009a6100c6366004610579565b610115565b6100de6100d936600461055e565b6101f5565b6040516100a791906105b3565b6100fe6100f93660046104c8565b61032b565b6040516100a79190610604565b600181565b600081565b600081600581111561012357fe5b61013b576101346020840184610537565b90506101ef565b81600581111561014757fe5b6001141561015f576101346040840160208501610537565b81600581111561016b57fe5b60021415610183576101346060840160408501610537565b81600581111561018f57fe5b600314156101a7576101346080840160608501610537565b8160058111156101b357fe5b600414156101cb5761013460a0840160808501610537565b8160058111156101d757fe5b600514156101ef5761013460c0840160a08501610537565b92915050565b60408051600680825260e082019092526060918291906020820160c0803683370190505090506102286020840184610537565b8160008151811061023557fe5b9115156020928302919091018201526102549060408501908501610537565b8160018151811061026157fe5b911515602092830291909101909101526102816060840160408501610537565b8160028151811061028e57fe5b911515602092830291909101909101526102ae6080840160608501610537565b816003815181106102bb57fe5b911515602092830291909101909101526102db60a0840160808501610537565b816004815181106102e857fe5b9115156020928302919091019091015261030860c0840160a08501610537565b8160058151811061031557fe5b9115156020928302919091019091015292915050565b61033361047c565b600682101561037757506040805160c081018252600080825260016020830181905292820192909252606081018290526080810182905260a08101919091526101ef565b6040518060c001604052808484600081811061038f57fe5b90506020020160208101906103a49190610537565b15158152602001848460018181106103b857fe5b90506020020160208101906103cd9190610537565b15158152602001848460028181106103e157fe5b90506020020160208101906103f69190610537565b151581526020018484600381811061040a57fe5b905060200201602081019061041f9190610537565b151581526020018484600481811061043357fe5b90506020020160208101906104489190610537565b151581526020018484600581811061045c57fe5b90506020020160208101906104719190610537565b1515905290506101ef565b6040805160c081018252600080825260208201819052918101829052606081018290526080810182905260a081019190915290565b600060c082840312156104c2578081fd5b50919050565b600080602083850312156104da578182fd5b823567ffffffffffffffff808211156104f1578384fd5b818501915085601f830112610504578384fd5b813581811115610512578485fd5b8660208083028501011115610525578485fd5b60209290920196919550909350505050565b600060208284031215610548578081fd5b81358015158114610557578182fd5b9392505050565b600060c0828403121561056f578081fd5b61055783836104b1565b60008060e0838503121561058b578182fd5b61059584846104b1565b915060c0830135600681106105a8578182fd5b809150509250929050565b6020808252825182820181905260009190848201906040850190845b818110156105ed5783511515835292840192918401916001016105cf565b50909695505050505050565b901515815260200190565b600060c08201905082511515825260208301511515602083015260408301511515604083015260608301511515606083015260808301511515608083015260a0830151151560a08301529291505056fea2646970667358221220335c43d47302ef8863c8df8dafb3f21e3f9af6b0e18ee836190bde3ede74f5fe64736f6c634300060c0033",
"deployedBytecode": "0x730000000000000000000000000000000000000000301460806040526004361061008d5760003560e01c806321bb04ae146100925780632cc0c346146100b05780633d027b9d146100b05780634583544a146100b8578063710a51c2146100cb578063c08473fc146100eb578063cb0d28f614610092578063dccf54e7146100b0578063fe7f62d1146100b0575b600080fd5b61009a61010b565b6040516100a791906105f9565b60405180910390f35b61009a610110565b61009a6100c6366004610579565b610115565b6100de6100d936600461055e565b6101f5565b6040516100a791906105b3565b6100fe6100f93660046104c8565b61032b565b6040516100a79190610604565b600181565b600081565b600081600581111561012357fe5b61013b576101346020840184610537565b90506101ef565b81600581111561014757fe5b6001141561015f576101346040840160208501610537565b81600581111561016b57fe5b60021415610183576101346060840160408501610537565b81600581111561018f57fe5b600314156101a7576101346080840160608501610537565b8160058111156101b357fe5b600414156101cb5761013460a0840160808501610537565b8160058111156101d757fe5b600514156101ef5761013460c0840160a08501610537565b92915050565b60408051600680825260e082019092526060918291906020820160c0803683370190505090506102286020840184610537565b8160008151811061023557fe5b9115156020928302919091018201526102549060408501908501610537565b8160018151811061026157fe5b911515602092830291909101909101526102816060840160408501610537565b8160028151811061028e57fe5b911515602092830291909101909101526102ae6080840160608501610537565b816003815181106102bb57fe5b911515602092830291909101909101526102db60a0840160808501610537565b816004815181106102e857fe5b9115156020928302919091019091015261030860c0840160a08501610537565b8160058151811061031557fe5b9115156020928302919091019091015292915050565b61033361047c565b600682101561037757506040805160c081018252600080825260016020830181905292820192909252606081018290526080810182905260a08101919091526101ef565b6040518060c001604052808484600081811061038f57fe5b90506020020160208101906103a49190610537565b15158152602001848460018181106103b857fe5b90506020020160208101906103cd9190610537565b15158152602001848460028181106103e157fe5b90506020020160208101906103f69190610537565b151581526020018484600381811061040a57fe5b905060200201602081019061041f9190610537565b151581526020018484600481811061043357fe5b90506020020160208101906104489190610537565b151581526020018484600581811061045c57fe5b90506020020160208101906104719190610537565b1515905290506101ef565b6040805160c081018252600080825260208201819052918101829052606081018290526080810182905260a081019190915290565b600060c082840312156104c2578081fd5b50919050565b600080602083850312156104da578182fd5b823567ffffffffffffffff808211156104f1578384fd5b818501915085601f830112610504578384fd5b813581811115610512578485fd5b8660208083028501011115610525578485fd5b60209290920196919550909350505050565b600060208284031215610548578081fd5b81358015158114610557578182fd5b9392505050565b600060c0828403121561056f578081fd5b61055783836104b1565b60008060e0838503121561058b578182fd5b61059584846104b1565b915060c0830135600681106105a8578182fd5b809150509250929050565b6020808252825182820181905260009190848201906040850190845b818110156105ed5783511515835292840192918401916001016105cf565b50909695505050505050565b901515815260200190565b600060c08201905082511515825260208301511515602083015260408301511515604083015260608301511515606083015260808301511515608083015260a0830151151560a08301529291505056fea2646970667358221220335c43d47302ef8863c8df8dafb3f21e3f9af6b0e18ee836190bde3ede74f5fe64736f6c634300060c0033",
"libraries": {},
"devdoc": {
"author": "Desyn Labs",
"kind": "dev",
"methods": {
"constructRights(bool[])": {
"details": "If you pass an empty array, it will construct it using the defaults",
"params": {
"a": "- array input"
},
"returns": {
"_0": "Rights struct"
}
},
"convertRights(RightsManager.Rights)": {
"details": "avoids multiple calls to hasPermission",
"params": {
"rights": "- the rights struct to convert"
},
"returns": {
"_0": "boolean array containing the rights settings"
}
},
"hasPermission(RightsManager.Rights,RightsManager.Permissions)": {
"params": {
"permission": "- The permission to check",
"self": "- Rights struct containing the permissions"
},
"returns": {
"_0": "Boolean true if it has the permission"
}
}
},
"title": "Manage Configurable Rights for the smart pool canPauseSwapping - can setPublicSwap back to false after turning it on by default, it is off on initialization and can only be turned on canChangeSwapFee - can setSwapFee after initialization (by default, it is fixed at create time) canChangeWeights - can bind new token weights (allowed by default in base pool) canAddRemoveTokens - can bind/unbind tokens (allowed by default in base pool) canWhitelistLPs - can limit liquidity providers to a given set of addresses canChangeCap - can change the BSP cap (max # of pool tokens) canChangeFloor - can change the BSP floor for Closure ETF (min # of pool tokens)",
"version": 1
},
"userdoc": {
"kind": "user",
"methods": {
"constructRights(bool[])": {
"notice": "create a struct from an array (or return defaults)"
},
"convertRights(RightsManager.Rights)": {
"notice": "Convert rights struct to an array (e.g., for events, GUI)"
},
"hasPermission(RightsManager.Rights,RightsManager.Permissions)": {
"notice": "Externally check permissions using the Enum"
}
},
"version": 1
},
"storageLayout": {
"storage": [],
"types": null
}
}