pub fn total_assets_for_fee_accrual(
cur_total_assets: u128,
anchor_total_assets: u128,
anchor_timestamp_ns: u64,
now_ns: u64,
max_rate: Option<Wad>,
) -> u128Expand description
Compute the effective total_assets for fee accrual, clamping growth to the max rate if configured.
When max_rate is Some, limits the effective total_assets to
anchor_total_assets * (1 + max_rate * elapsed / YEAR).