pub type UstrDiscreteTabModel = DiscreteTabModel<Ustr, Ustr, BuildHasherDefault<IdentityHasher>>;
Expand description
A model of a discrete tabulator theory where both theory and model have keys
of type Ustr
.
Aliased Type§
struct UstrDiscreteTabModel { /* private fields */ }
Implementations
Source§impl<Id, ThId, S> DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> DiscreteTabModel<Id, ThId, S>
Sourcepub fn new(theory: Arc<DiscreteTabTheory<ThId, ThId, S>>) -> Self
pub fn new(theory: Arc<DiscreteTabTheory<ThId, ThId, S>>) -> Self
Creates an empty model of the given theory.
Sourcepub fn tabulated(&self, mor: TabMor<Id, Id>) -> TabOb<Id, Id>
pub fn tabulated(&self, mor: TabMor<Id, Id>) -> TabOb<Id, Id>
Convenience method to turn a morphism into an object.
Sourcepub fn tabulated_gen(&self, f: Id) -> TabOb<Id, Id>
pub fn tabulated_gen(&self, f: Id) -> TabOb<Id, Id>
Convenience method to turn a morphism generator into an object.
Sourcepub fn iter_invalid(&self) -> impl Iterator<Item = InvalidDblModel<Id>> + '_
pub fn iter_invalid(&self) -> impl Iterator<Item = InvalidDblModel<Id>> + '_
Iterates over failures of model to be well defined.
Trait Implementations
Source§impl<Id, ThId, S> Category for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> Category for DiscreteTabModel<Id, ThId, S>
Source§fn has_mor(&self, path: &Self::Mor) -> bool
fn has_mor(&self, path: &Self::Mor) -> bool
Does the category contain the value as a morphism?
Source§fn compose(&self, path: Path<Self::Ob, Self::Mor>) -> Self::Mor
fn compose(&self, path: Path<Self::Ob, Self::Mor>) -> Self::Mor
Composes a path of morphisms in the category.
Source§impl<Id: Clone, ThId: Clone, S: Clone> Clone for DiscreteTabModel<Id, ThId, S>
impl<Id: Clone, ThId: Clone, S: Clone> Clone for DiscreteTabModel<Id, ThId, S>
Source§fn clone(&self) -> DiscreteTabModel<Id, ThId, S>
fn clone(&self) -> DiscreteTabModel<Id, ThId, S>
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<Id, ThId, S> DblModel for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> DblModel for DiscreteTabModel<Id, ThId, S>
Source§type MorType = TabMorType<ThId, ThId>
type MorType = TabMorType<ThId, ThId>
Rust type of morphism types defined in the theory.
Source§type ObOp = Path<TabObType<ThId, ThId>, TabObProj<ThId, ThId>>
type ObOp = Path<TabObType<ThId, ThId>, TabObProj<ThId, ThId>>
Type of operations on objects defined in the theory.
Source§type Theory = DiscreteTabTheory<ThId, ThId, S>
type Theory = DiscreteTabTheory<ThId, ThId, S>
The type of double theory that this is a model of.
Source§impl<Id, ThId, S> FgCategory for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> FgCategory for DiscreteTabModel<Id, ThId, S>
Source§fn ob_generators(&self) -> impl Iterator<Item = Self::ObGen>
fn ob_generators(&self) -> impl Iterator<Item = Self::ObGen>
Iterates over object generators.
Source§fn mor_generators(&self) -> impl Iterator<Item = Self::MorGen>
fn mor_generators(&self) -> impl Iterator<Item = Self::MorGen>
Iterates over morphism generators.
Source§fn mor_generator_dom(&self, f: &Self::MorGen) -> Self::Ob
fn mor_generator_dom(&self, f: &Self::MorGen) -> Self::Ob
The domain of a morphism generator
Source§fn mor_generator_cod(&self, f: &Self::MorGen) -> Self::Ob
fn mor_generator_cod(&self, f: &Self::MorGen) -> Self::Ob
The codomain of a morphism generator
Source§impl<Id, ThId, S> FgDblModel for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> FgDblModel for DiscreteTabModel<Id, ThId, S>
Source§fn ob_generator_type(&self, ob: &Self::ObGen) -> Self::ObType
fn ob_generator_type(&self, ob: &Self::ObGen) -> Self::ObType
Type of an object generator.
Source§fn mor_generator_type(&self, mor: &Self::MorGen) -> Self::MorType
fn mor_generator_type(&self, mor: &Self::MorGen) -> Self::MorType
Type of a morphism generator.
Source§fn ob_generators_with_type(
&self,
obtype: &Self::ObType,
) -> impl Iterator<Item = Self::ObGen>
fn ob_generators_with_type( &self, obtype: &Self::ObType, ) -> impl Iterator<Item = Self::ObGen>
Iterates over object generators with the given object type.
Source§fn mor_generators_with_type(
&self,
mortype: &Self::MorType,
) -> impl Iterator<Item = Self::MorGen>
fn mor_generators_with_type( &self, mortype: &Self::MorType, ) -> impl Iterator<Item = Self::MorGen>
Iterates over morphism generators with the given morphism type.
Source§impl<Id, ThId, S> MutDblModel for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> MutDblModel for DiscreteTabModel<Id, ThId, S>
Source§fn add_ob(&mut self, x: Self::ObGen, ob_type: Self::ObType) -> bool
fn add_ob(&mut self, x: Self::ObGen, ob_type: Self::ObType) -> bool
Adds a basic object to the model.
Source§fn make_mor(&mut self, f: Self::MorGen, mor_type: Self::MorType) -> bool
fn make_mor(&mut self, f: Self::MorGen, mor_type: Self::MorType) -> bool
Adds a basic morphism to the model without setting its (co)domain.
Source§fn get_dom(&self, f: &Self::MorGen) -> Option<&Self::Ob>
fn get_dom(&self, f: &Self::MorGen) -> Option<&Self::Ob>
Gets the domain of a basic morphism, if it is set.
Source§fn get_cod(&self, f: &Self::MorGen) -> Option<&Self::Ob>
fn get_cod(&self, f: &Self::MorGen) -> Option<&Self::Ob>
Gets the codomain of a basic morphism, if it is set.
Source§fn set_dom(&mut self, f: Self::MorGen, x: Self::Ob) -> Option<Self::Ob>
fn set_dom(&mut self, f: Self::MorGen, x: Self::Ob) -> Option<Self::Ob>
Sets the domain of a basic morphism.
Source§impl<Id, ThId, S> PartialEq for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> PartialEq for DiscreteTabModel<Id, ThId, S>
Source§impl<Id, ThId, S> Validate for DiscreteTabModel<Id, ThId, S>
impl<Id, ThId, S> Validate for DiscreteTabModel<Id, ThId, S>
Source§type ValidationError = InvalidDblModel<Id>
type ValidationError = InvalidDblModel<Id>
The type of a validation error. Read more