pub struct DblTheory(pub DblTheoryBox);Expand description
Wasm binding for a double theory.
Tuple Fields§
§0: DblTheoryBoxImplementations§
Source§impl DblTheory
impl DblTheory
Sourcepub fn src(&self, mor_type: MorType) -> Result<ObType, String>
pub fn src(&self, mor_type: MorType) -> Result<ObType, String>
Gets the source of a morphism type.
Sourcepub fn tgt(&self, mor_type: MorType) -> Result<ObType, String>
pub fn tgt(&self, mor_type: MorType) -> Result<ObType, String>
Gets the target of a morphism type.
Sourcepub fn cod(&self, op: ObOp) -> Result<ObType, String>
pub fn cod(&self, op: ObOp) -> Result<ObType, String>
Gets the codomain of an object operation.
Sourcepub fn can_instantiate_models(&self) -> bool
pub fn can_instantiate_models(&self) -> bool
Does the theory support instantiating models in other models?
Eventually instantiation should be supported for every double doctrine and then this method can be removed.
Trait Implementations§
Source§impl FromWasmAbi for DblTheory
impl FromWasmAbi for DblTheory
Source§impl IntoWasmAbi for DblTheory
impl IntoWasmAbi for DblTheory
Source§impl LongRefFromWasmAbi for DblTheory
impl LongRefFromWasmAbi for DblTheory
Source§impl OptionFromWasmAbi for DblTheory
impl OptionFromWasmAbi for DblTheory
Source§impl OptionIntoWasmAbi for DblTheory
impl OptionIntoWasmAbi for DblTheory
Source§impl RefFromWasmAbi for DblTheory
impl RefFromWasmAbi for DblTheory
Source§impl RefMutFromWasmAbi for DblTheory
impl RefMutFromWasmAbi for DblTheory
Source§impl TryFromJsValue for DblTheory
impl TryFromJsValue for DblTheory
Source§impl VectorFromWasmAbi for DblTheory
impl VectorFromWasmAbi for DblTheory
Source§impl VectorIntoWasmAbi for DblTheory
impl VectorIntoWasmAbi for DblTheory
impl SupportsConstructor for DblTheory
impl SupportsInstanceProperty for DblTheory
impl SupportsStaticProperty for DblTheory
Auto Trait Implementations§
impl Freeze for DblTheory
impl !RefUnwindSafe for DblTheory
impl !Send for DblTheory
impl !Sync for DblTheory
impl Unpin for DblTheory
impl !UnwindSafe for DblTheory
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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 moreSource§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::AbiSource§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as
IntoWasmAbi::into_abi, except that it may throw and never
return in the case of Err.§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
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
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
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
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.