pub struct Connection {
pub kind: String,
pub source: String,
pub target: String,
pub action: GeneratorAction,
pub laws: Vec<String>,
}Expand description
The uniform serialized morphism.
Fields§
§kind: StringThe specific kind, resolved against the meta-ontology (e.g.
"FullyFaithful", "FreeForgetful"). The action variant names the
family; kind refines it.
source: StringThe source category/ontology name.
target: StringThe target category/ontology name.
action: GeneratorActionThe finite action-on-generators that IS this connection.
laws: Vec<String>Names of the laws this connection must satisfy (functor laws, the triangle identities, the lens laws, …) — carried uniformly as data.
Implementations§
Source§impl Connection
impl Connection
Sourcepub fn address(&self) -> Result<ContentAddress, CodecError>
pub fn address(&self) -> Result<ContentAddress, CodecError>
The content address of this connection — its definition-bearing identity, over the canonical (sorted) action + laws.
Trait Implementations§
Source§impl Clone for Connection
impl Clone for Connection
Source§fn clone(&self) -> Connection
fn clone(&self) -> Connection
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Connection
impl Debug for Connection
Source§impl<'de> Deserialize<'de> for Connection
impl<'de> Deserialize<'de> for Connection
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Connection
Source§impl PartialEq for Connection
impl PartialEq for Connection
Source§fn eq(&self, other: &Connection) -> bool
fn eq(&self, other: &Connection) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for Connection
impl Serialize for Connection
impl StructuralPartialEq for Connection
Auto Trait Implementations§
impl Freeze for Connection
impl RefUnwindSafe for Connection
impl Send for Connection
impl Sync for Connection
impl Unpin for Connection
impl UnsafeUnpin for Connection
impl UnwindSafe for Connection
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