StakePoolProgramHelper class

Constructors

StakePoolProgramHelper()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

calcPoolTokensForDeposit(StakePoolAccount stakePoolAccount, BigInt stakeLamports) BigInt
Calculate the pool tokens that should be minted for a deposit of stakeLamports
createPoolTokenMetadata({required SolanaRPC rpc, required SolAddress stakePoolAddress, required SolAddress payer, required String name, required String symbol, required String uri}) Future<List<TransactionInstruction>>
Creates instructions required to create pool token metadata.
decreaseValidatorStake(SolanaRPC connection, SolAddress stakePoolAddress, SolAddress validatorVote, BigInt lamports, {BigInt? ephemeralStakeSeed}) Future<List<TransactionInstruction>>
Creates instructions required to decrease validator stake.
depositSol({required SolanaRPC connection, required SolAddress stakePoolAddress, required SolAddress from, required SolAddress userSolTransfer, required BigInt lamports, SolAddress? destinationTokenAccount, SolAddress? referrerTokenAccount, required SolAddress depositAuthority}) Future<List<TransactionInstruction>>
Creates instructions required to deposit sol to stake pool.
depositStake({required SolanaRPC rpc, required SolAddress stakePoolAddress, required SolAddress authorizedPubkey, required SolAddress validatorVote, required SolAddress depositStake, required SolAddress? poolTokenReceiverAccount}) Future<List<TransactionInstruction>>
Creates instructions required to deposit stake to stake pool.
increaseValidatorStake({required SolanaRPC connection, required SolAddress stakePoolAddress, required SolAddress validatorVote, required BigInt lamports, BigInt? ephemeralStakeSeed}) Future<List<TransactionInstruction>>
Creates instructions required to increase validator stake.
prepareWithdrawAccounts({required SolanaRPC connection, required StakePoolAccount stakePool, required SolAddress stakePoolAddress, required BigInt amount, bool skipFee = false, Comparator<ValidatorAccount>? compareFn}) Future<List<WithdrawAccount>>
redelegate({required SolanaRPC connection, required SolAddress stakePoolAddress, required SolAddress sourceVoteAccount, required BigInt sourceTransientStakeSeed, required SolAddress destinationVoteAccount, required BigInt destinationTransientStakeSeed, required BigInt ephemeralStakeSeed, required BigInt lamports}) Future<List<TransactionInstruction>>
Creates instructions required to redelegate stake.
updatePoolTokenMetadata({required SolanaRPC rpc, required SolAddress stakePoolAddress, required String name, required String symbol, required String uri}) Future<List<TransactionInstruction>>
Creates instructions required to update pool token metadata.
updateStakePool(SolanaRPC connection, StakePoolAccount stakePool, {bool noMerge = false}) Future<Tuple<List<TransactionInstruction>, List<TransactionInstruction>>>
Creates instructions required to completely update a stake pool after epoch change.
withdrawSol({required SolanaRPC connection, required SolAddress stakePoolAddress, required SolAddress tokenOwner, required SolAddress solReceiver, required SolAddress userTransferAuthority, required BigInt poolAmountLamports, SolAddress? solWithdrawAuthority}) Future<List<TransactionInstruction>>
Creates instructions required to withdraw SOL directly from a stake pool.