StakePoolProgram.updateStakePoolBalance constructor
StakePoolProgram.updateStakePoolBalance({
- required SolAddress stakePool,
- required SolAddress withdrawAuthority,
- required SolAddress validatorList,
- required SolAddress reserveStake,
- required SolAddress managerFeeAccount,
- required SolAddress poolMint,
Updates total pool balance based on balances in the reserve and validator list
Implementation
factory StakePoolProgram.updateStakePoolBalance({
/// Stake pool
required SolAddress stakePool,
/// Stake pool withdraw authority
required SolAddress withdrawAuthority,
/// Validator stake list storage account
required SolAddress validatorList,
/// Reserve stake account
required SolAddress reserveStake,
/// Account to receive pool fee tokens
required SolAddress managerFeeAccount,
/// Pool mint account
required SolAddress poolMint,
}) {
return StakePoolProgram(
layout: const StakePoolUpdateStakePoolBalanceLayout(),
keys: [
stakePool.toWritable(),
withdrawAuthority.toReadOnly(),
validatorList.toWritable(),
reserveStake.toReadOnly(),
managerFeeAccount.toWritable(),
poolMint.toWritable(),
SPLTokenProgramConst.tokenProgramId.toReadOnly()
],
programId: StakePoolProgramConst.programId);
}