Trait typed_graph::Typed

source ·
pub trait Typed: PartialEq<Self::Type> {
    type Type: TypeIdentifier;

    // Required method
    fn get_type(&self) -> Self::Type;
}

Required Associated Types§

Required Methods§

source

fn get_type(&self) -> Self::Type

Retrieve a runtime representation of the type of the node or edge

PartialEq can then be used on the returned type to check if other nodes has the same type

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<K: Key, T: GenericTypeIdentifier> Typed for GenericWeight<K, T>

§

type Type = T

source§

impl<Old: Typed, New: Typed> Typed for EitherVersion<Old, New>

§

type Type = EitherVersion<<Old as Typed>::Type, <New as Typed>::Type>