pub struct PrincipalQuotas {
pub requests_per_window: u64,
pub input_tokens_per_window: u64,
pub output_tokens_per_window: u64,
pub window: Duration,
pub allowed_models: Vec<String>,
}Expand description
Per-principal quota window and model allow-list.
Fields§
§requests_per_window: u64Maximum request count allowed within window.
input_tokens_per_window: u64Maximum input token count allowed within window.
output_tokens_per_window: u64Maximum output token count allowed within window.
window: DurationQuota window duration.
allowed_models: Vec<String>Glob-style model names allowed for this principal.
Trait Implementations§
Source§impl Clone for PrincipalQuotas
impl Clone for PrincipalQuotas
Source§fn clone(&self) -> PrincipalQuotas
fn clone(&self) -> PrincipalQuotas
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 moreSource§impl Debug for PrincipalQuotas
impl Debug for PrincipalQuotas
impl Eq for PrincipalQuotas
Source§impl PartialEq for PrincipalQuotas
impl PartialEq for PrincipalQuotas
Source§fn eq(&self, other: &PrincipalQuotas) -> bool
fn eq(&self, other: &PrincipalQuotas) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PrincipalQuotas
Auto Trait Implementations§
impl Freeze for PrincipalQuotas
impl RefUnwindSafe for PrincipalQuotas
impl Send for PrincipalQuotas
impl Sync for PrincipalQuotas
impl Unpin for PrincipalQuotas
impl UnsafeUnpin for PrincipalQuotas
impl UnwindSafe for PrincipalQuotas
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