pub struct UsageLimit {
pub provider: &'static str,
pub scope: UsageLimitScope,
pub reset_at: Option<DateTime<Utc>>,
pub raw: String,
}Expand description
A successful detection of an upstream usage / rate limit.
Fields§
§provider: &'static str§scope: UsageLimitScope§reset_at: Option<DateTime<Utc>>When usage resets, if the provider gave us something parseable.
None means “we don’t know” — compute_resume_at will fall back to
default_fallback_secs.
raw: StringThe exact substring or JSON snippet that matched. Recorded into the session log so future maintainers can see why detection fired even after the upstream format has drifted.
Trait Implementations§
Source§impl Clone for UsageLimit
impl Clone for UsageLimit
Source§fn clone(&self) -> UsageLimit
fn clone(&self) -> UsageLimit
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for UsageLimit
impl RefUnwindSafe for UsageLimit
impl Send for UsageLimit
impl Sync for UsageLimit
impl Unpin for UsageLimit
impl UnsafeUnpin for UsageLimit
impl UnwindSafe for UsageLimit
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more