PALMManager
Manager contract of all PALM vaults
Last updated
Manager contract of all PALM vaults
Last updated
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
perform a ArrakisV2.rebalance
operation on a PALM vault.
parameters :
modifiers :
when not paused
msg.sender
in operators
list in state
vault_
is added (VaultInfo initialized)
checks :
check that feeAmount_
is LTE vault_
balance
events :
RebalanceVault(address indexed vault, uint256 newBalance)
register a vault to be managed by PALMManager
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
owner is PALMTerms
msg.sender is PALMTerms
checks :
check that strat_
is a whitelisted strategy
check that vault_
is not already added (stored VaultInfo)
events :
AddVault(address indexed vault, bytes datas, string strat)
UpdateVaultBalance(address indexed vault, uint256 newBalance)
(possibly)
remove vault from PALMManager managed vaults. Any network token in vault balance will be withdrawn
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
owner is msg.sender
checks :
check that vault_
is already added (stored VaultInfo)
events :
RemoveVault(address indexed vault, uint256 sendBack)
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
is already added (VaultInfo stored)
msg.sender
is terms
address
events :
SetTermEnd(address indexed vault, uint256 oldtermEnd, uint256 newtermEnd)
increase vault balance
(Gas Tank) with msg.value
network token
parameters :
modifiers :
when not paused
vault_
is already added (VaultInfo stored)
events :
UpdateVaultBalance(address indexed vault, uint256 newBalance)
set/reset vault datas
bytes
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
owner is msg.sender
vault_
already added (VaultInfo stored)
checks :
check that data_
is not same as existing stored
events :
SetVaultData(address indexed vault, bytes data)
set/reset vault strategy type (from whitelisted list)
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
owner is msg.sender
vault_
already added (VaultInfo stored)
checks :
check that strat_
is not same as existing stored
check that strat_
is a whilelisted strategy
events :
SetVaultStrat(address indexed vault, bytes32 strat)
decrease balance
(Gas Tank) of vault, receive network tokens
parameters :
modifiers :
when not paused
vault_
non-zero address
vault_
owner is msg.sender
vault_
already added (VaultInfo stored)
to_
non-zero address
checks :
vault balance exceeds amount_
to withdraw
WithdrawVaultBalance(address indexed vault, uint256 amount, address to, uint256 newBalance)
PALMManager admin adds keeper operator addresses
parameters :
modifiers :
when not paused
msg.sender
is Manager-wide _owner
checks :
check that operators_
are not already in operators array
events :
AddOperators(address[] operators)
PALMManager admin removes keeper operator addresses
parameters :
modifiers :
when not paused
msg.sender
is Manager-wide _owner
checks :
check that operators_
are already in operators arraye
events :
RemoveOperators(address[] operators)
PALMManager admin withdraws any manager fees earned
parameters :
modifiers :
when not paused
msg.sender
is Manager-wide _owner
Ownable (transferOwnership)
Pausable (pause, unpause)
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
name | type | description |
---|---|---|
managerFeeBPS
uint16
fee on fees earned taken by this manager (in BPS of fees earned)
terms
address
Terms address
termDuration
uint256
number of seconds of a Term
vaults
mapping(address => VaultInfo)
Basic information per vault in storage (balance, strat, data, termEnd)
operators
address[]
list of whitelisted operators who can call rebalance method on vaults
gelatoFeeCollector
address
address to collect gas fees for Gelato automated executions.
_owner
address
Owner of PALMManager contract who can set Manager-wide configurable parameters
_whitelistedStrat
Bytes32Set
set of whitelisted strategy identifiers keccak256("stratName")
balance
uint256
Gas Tank balance for repaying keepers for rebalance gas costs
lastRebalance
uint256
timestamp of last rebalance
datas
bytes
JSON encoded custom parameters to strategy
strat
bytes32
Selected Strategy type encoded askeccak256(stratString)
vault_
address
Vault address
rebalanceParams_
Rebalance
Struct with rebalance operation information
feeAmount_
uint256
amount paid in fee to Gelato
vault_
address
Vault address
datas_
bytes
amount of LP token to mint on first mint (arbitrary)
strat_
string
strategy string identifier
vault_
address
Vault address
to_
address
receiver of network token if vault is funded
vault_
address
Vault address
to_
address
receiver of network token if vault is funded
vault_
address
Vault address
vault_
address
Vault address
data_
bytes
new Vault data
vault_
address
Vault address
strat_
string
strategy string identifier for vault
vault_
address
Vault address
amount_
uint256
amount of Network Token to withdraw
to_
address
receiver of Network Token
operators_
address[]
new operators (authorized to call rebalance for all vaults)
operators_
address[]
operators to remove
tokens_
address[]
token addresses to remove
to_
address
receiver of tokens (fees earned by manager)