Skip to main content

quota_charge

Function quota_charge 

Source
pub fn quota_charge(
    available: u64,
    debt: u64,
    requested: u64,
    burst: u64,
    debt_cap: u64,
) -> (u64, u64)
Expand description

Charge the effective micro-token request in full, retaining its unpaid portion as debt up to debt_cap.

A smaller cap intentionally forgets debt; u64::MAX is the unbounded mode’s representability limit.