This method allows the user to collect the rewards accrued on their position. Only the reward of the provided RewardCoinType
are collected, so the user must call this method separately for each reward coin they want to collect. The following interfaces can be used to call the method, with the arguments described below:
Interfaces
public fun collect_reward<CoinTypeA, CoinTypeB, RewardCoinType>(
clock: &Clock,
protocol_config: &GlobalConfig,
pool: &mut Pool<CoinTypeA, CoinTypeB>,
position: &mut Position,
ctx: &mut TxContext) {
abort 0
}
}
/// Parameters:
/// - clock : Sui clock object
/// - protocol_config : The `config::GlobalConfig` object used for version verification
/// - pool : Mutable reference to the pool on which the position exists
/// - position : The position for which the rewards are to be collected
/// - ctx : Murable reference to caller's transaction context
///
/// Events Emitted : UserRewardCollected