pub trait TypedNodeStore<IdN: TypedNodeId> {
    type R<'a>: Typed<Type = IdN::Ty>
       where Self: 'a;

    // Required methods
    fn try_typed(&self, id: &IdN::IdN) -> Option<IdN>;
    fn resolve(&self, id: &IdN) -> Self::R<'_>;

    // Provided method
    fn try_resolve(&self, id: &IdN::IdN) -> Option<(Self::R<'_>, IdN)> { ... }
}

Required Associated Types§

source

type R<'a>: Typed<Type = IdN::Ty> where Self: 'a

Required Methods§

source

fn try_typed(&self, id: &IdN::IdN) -> Option<IdN>

source

fn resolve(&self, id: &IdN) -> Self::R<'_>

Provided Methods§

source

fn try_resolve(&self, id: &IdN::IdN) -> Option<(Self::R<'_>, IdN)>

Implementors§

source§

impl<TIdN: 'static + TypedNodeId<IdN = NodeIdentifier>> TypedNodeStore<TIdN> for hyper_ast::store::nodes::legion::NodeStore

§

type R<'a> = HashedNodeRef<'a, TIdN>

source§

impl<TIdN: TypedNodeId> TypedNodeStore<TIdN> for hyper_ast::store::nodes::fetched::NodeStorewhere TIdN::Ty: TypeTrait,

§

type R<'a> = HashedNodeRef<'a, TIdN>