pub struct Restriction { /* private fields */ }Implementations§
Source§impl Restriction
impl Restriction
pub fn new() -> Self
pub fn set_nbf(&mut self, nbf: DateTime<Utc>)
pub fn set_exp(&mut self, exp: DateTime<Utc>)
pub fn add_scope<T: ToString>(&mut self, scope: T)
pub fn add_audiences<I, T>(&mut self, audiences: I)where
I: IntoIterator<Item = T>,
T: ToString,
pub fn add_ips<I, T>(&mut self, hosts: I)where
I: IntoIterator<Item = T>,
T: ToString,
pub fn add_geoip_allow<I, T>(&mut self, geoip_allow: I)where
I: IntoIterator<Item = T>,
T: ToString,
pub fn add_geoip_disallow<I, T>(&mut self, geoip_disallow: I)where
I: IntoIterator<Item = T>,
T: ToString,
pub fn set_usage_AT(&mut self, n: u64)
pub fn set_usage_other(&mut self, n: u64)
pub fn builder() -> RestrictionBuilder
Trait Implementations§
Source§impl Clone for Restriction
impl Clone for Restriction
Source§fn clone(&self) -> Restriction
fn clone(&self) -> Restriction
Returns a copy of the value. Read more
1.0.0 · 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 Restriction
impl Debug for Restriction
Source§impl Default for Restriction
impl Default for Restriction
Source§impl<'de> Deserialize<'de> for Restriction
impl<'de> Deserialize<'de> for Restriction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Hash for Restriction
impl Hash for Restriction
Source§impl PartialEq for Restriction
impl PartialEq for Restriction
Source§impl Serialize for Restriction
impl Serialize for Restriction
impl Eq for Restriction
impl StructuralPartialEq for Restriction
Auto Trait Implementations§
impl Freeze for Restriction
impl RefUnwindSafe for Restriction
impl Send for Restriction
impl Sync for Restriction
impl Unpin for Restriction
impl UnwindSafe for Restriction
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