Struct Computad

Source
pub struct Computad<'a, Ob, ObSet, E, S = RandomState> { /* private fields */ }
Expand description

A 1-computad.

The set of objects is assumed already constructed, possibly from other generating data, while the top-dimensional generating data is provided directly.

Implementations§

Source§

impl<'a, Ob, ObSet, E, S> Computad<'a, Ob, ObSet, E, S>

Source

pub const fn new( objects: &'a ObSet, computad: &'a ComputadTop<Ob, E, S>, ) -> Computad<'a, Ob, ObSet, E, S>

Trait Implementations§

Source§

impl<'a, Ob, ObSet, E, S> ColumnarGraph for Computad<'a, Ob, ObSet, E, S>
where Ob: Eq + Clone, ObSet: Set<Elem = Ob>, E: Eq + Clone + Hash, S: BuildHasher,

Source§

type V = Ob

Type of vertices in the graph.
Source§

type E = E

Type of edges in the graph.
Source§

type Vertices = ObSet

The set of vertices.
Source§

type Edges = HashFinSet<E, S>

The set of edges.
Source§

type Src = HashColumn<E, Ob, S>

The map assigning each edge its source vertex.
Source§

type Tgt = HashColumn<E, Ob, S>

The map assigning each edge its target vertex.
Source§

fn vertex_set(&self) -> &Self::Vertices

Gets the set of vertices.
Source§

fn edge_set(&self) -> &Self::Edges

Gets the set of edges.
Source§

fn src_map(&self) -> &Self::Src

Gets the mapping assigning a source vertex to each edge.
Source§

fn tgt_map(&self) -> &Self::Tgt

Gets the mapping assignment a target vertex to each edge.
Source§

fn iter_invalid(&self) -> impl Iterator<Item = InvalidGraph<Self::E>>
where Self::Edges: FinSet<Elem = Self::E>,

Iterates over failures to be a valid graph.

Auto Trait Implementations§

§

impl<'a, Ob, ObSet, E, S> Freeze for Computad<'a, Ob, ObSet, E, S>

§

impl<'a, Ob, ObSet, E, S> RefUnwindSafe for Computad<'a, Ob, ObSet, E, S>

§

impl<'a, Ob, ObSet, E, S> Send for Computad<'a, Ob, ObSet, E, S>
where ObSet: Sync, S: Sync, E: Sync, Ob: Sync,

§

impl<'a, Ob, ObSet, E, S> Sync for Computad<'a, Ob, ObSet, E, S>
where ObSet: Sync, S: Sync, E: Sync, Ob: Sync,

§

impl<'a, Ob, ObSet, E, S> Unpin for Computad<'a, Ob, ObSet, E, S>

§

impl<'a, Ob, ObSet, E, S> UnwindSafe for Computad<'a, Ob, ObSet, E, S>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<G> Graph for G
where G: ColumnarGraph,

Source§

type V = <G as ColumnarGraph>::V

Type of vertices in graph.
Source§

type E = <G as ColumnarGraph>::E

Type of edges in graph.
Source§

fn has_vertex(&self, v: &<G as Graph>::V) -> bool

Does the graph contain the value as a vertex?
Source§

fn has_edge(&self, e: &<G as Graph>::E) -> bool

Does the graph contain the value as an edge?
Source§

fn src(&self, e: &<G as Graph>::E) -> <G as Graph>::V

Gets the source of an edge, assumed to be contained in the graph.
Source§

fn tgt(&self, e: &<G as Graph>::E) -> <G as Graph>::V

Gets the target of an edge, assumed to be contained in the graph.
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

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

§

fn to_subset(&self) -> Option<SS>

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more
§

fn is_in_subset(&self) -> bool

Checks if self is actually part of its subset T (and can be converted to it).
§

fn to_subset_unchecked(&self) -> SS

Use with care! Same as self.to_subset but without any property checks. Always succeeds.
§

fn from_subset(element: &SS) -> SP

The inclusion map: converts self to the equivalent element of its superset.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.