[−][src]Struct phf::set::Set  
An immutable set constructed at compile time.
Note
The fields of this struct are public so that they may be initialized by the
phf_set! macro and code generation. They are subject to change at any
time and should never be accessed directly.
Implementations
impl<T> Set<T>[src]
pub fn len(&self) -> usize[src]
Returns the number of elements in the Set.
pub fn is_empty(&self) -> bool[src]
Returns true if the Set contains no elements.
pub fn get_key<U: ?Sized>(&self, key: &U) -> Option<&T> where
    U: Eq + PhfHash,
    T: Borrow<U>, [src]
U: Eq + PhfHash,
T: Borrow<U>,
Returns a reference to the set's internal static instance of the given key.
This can be useful for interning schemes.
pub fn contains<U: ?Sized>(&self, value: &U) -> bool where
    U: Eq + PhfHash,
    T: Borrow<U>, [src]
U: Eq + PhfHash,
T: Borrow<U>,
Returns true if value is in the Set.
pub fn iter<'a>(&'a self) -> Iter<'a, T>[src]
Returns an iterator over the values in the set.
Values are returned in an arbitrary but fixed order.
impl<T> Set<T> where
    T: Eq + PhfHash, [src]
T: Eq + PhfHash,
pub fn is_disjoint(&self, other: &Set<T>) -> bool[src]
Returns true if other shares no elements with self.
pub fn is_subset(&self, other: &Set<T>) -> bool[src]
Returns true if other contains all values in self.
pub fn is_superset(&self, other: &Set<T>) -> bool[src]
Returns true if self contains all values in other.
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Set<T> where
    T: RefUnwindSafe, 
T: RefUnwindSafe,
impl<T> Send for Set<T> where
    T: Send + Sync, 
T: Send + Sync,
impl<T> Sync for Set<T> where
    T: Sync, 
T: Sync,
impl<T> Unpin for Set<T> where
    T: Unpin, 
T: Unpin,
impl<T> UnwindSafe for Set<T> where
    T: RefUnwindSafe + UnwindSafe, 
T: RefUnwindSafe + UnwindSafe,
Blanket Implementations
impl<T> Any for T where
    T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
    T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
    T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
    U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
    U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, [src]
U: TryFrom<T>,