[][src]Struct flag_algebra::operator::Type

pub struct Type<F> {
    pub size: usize,
    pub id: usize,
    // some fields omitted
}

Type (or root) of a flag. It is identified by its size and its id in the list of flags of that size.

Fields

size: usize

Size of the type.

id: usize

Index of the type in the list of unlabeled flags of this size.

Implementations

impl<F> Type<F>[src]

pub fn new(size: usize, id: usize) -> Self[src]

Constructor for the type.

pub fn empty() -> Self[src]

Create a type of size 0.

pub fn is_empty(&self) -> bool[src]

Return wether the input has size zero.

pub fn from_flag<G>(g: &G) -> Self where
    F: Flag,
    G: Into<F> + Clone
[src]

Create the type corresponding to g

pub fn types_with_size(size: usize) -> impl Iterator<Item = Self> where
    F: Flag
[src]

Iterate on all types of a given size.

pub fn print_concise(&self) -> String[src]

Print the type identifier in a short way.

Trait Implementations

impl<F> Clone for Type<F>[src]

impl<F> Copy for Type<F>[src]

impl<F: Debug> Debug for Type<F>[src]

impl<F> Display for Type<F>[src]

impl<F> Eq for Type<F>[src]

impl<F: Hash> Hash for Type<F>[src]

impl<F> Ord for Type<F>[src]

impl<F> PartialEq<Type<F>> for Type<F>[src]

impl<F> PartialOrd<Type<F>> for Type<F>[src]

Auto Trait Implementations

impl<F> RefUnwindSafe for Type<F> where
    F: RefUnwindSafe

impl<F> Send for Type<F> where
    F: Send

impl<F> Sync for Type<F> where
    F: Sync

impl<F> Unpin for Type<F> where
    F: Unpin

impl<F> UnwindSafe for Type<F> where
    F: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T[src]

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,