cairo_lang_syntax::node::db

Trait SyntaxGroup

source
pub trait SyntaxGroup:
    Database
    + HasQueryGroup<SyntaxDatabase>
    + FilesGroup
    + Upcast<dyn FilesGroup> {
    // Required methods
    fn intern_green(&self, field: Arc<GreenNode>) -> GreenId;
    fn lookup_intern_green(&self, key: GreenId) -> Arc<GreenNode>;
    fn intern_stable_ptr(&self, field: SyntaxStablePtr) -> SyntaxStablePtrId;
    fn lookup_intern_stable_ptr(
        &self,
        key: SyntaxStablePtrId,
    ) -> SyntaxStablePtr;
    fn get_children(&self, node: SyntaxNode) -> Arc<[SyntaxNode]>;
}

Required Methods§

Trait Implementations§

source§

impl<'a> DebugWithDb<dyn SyntaxGroup + 'a> for Attribute

source§

fn fmt(&self, f: &mut Formatter<'_>, db: &(dyn SyntaxGroup + 'a)) -> Result

source§

fn debug<'me, 'db>(&'me self, db: &'me Db) -> DebugWith<'me, Db>
where Self: Sized + 'me,

source§

fn into_debug<'me, 'db>(self, db: &'me Db) -> DebugWith<'me, Db>
where Self: Sized + 'me,

source§

impl<'a> Intern<'a, dyn SyntaxGroup + 'a, GreenId> for Arc<GreenNode>

source§

fn intern(self, db: &(impl Upcast<dyn SyntaxGroup + 'a> + ?Sized)) -> GreenId

source§

impl<'a> Intern<'a, dyn SyntaxGroup + 'a, SyntaxStablePtrId> for SyntaxStablePtr

source§

fn intern( self, db: &(impl Upcast<dyn SyntaxGroup + 'a> + ?Sized), ) -> SyntaxStablePtrId

source§

impl<'a> LookupIntern<'a, dyn SyntaxGroup + 'a, Arc<GreenNode>> for GreenId

source§

fn lookup_intern( &self, db: &(impl Upcast<dyn SyntaxGroup + 'a> + ?Sized), ) -> Arc<GreenNode>

source§

impl<'a> LookupIntern<'a, dyn SyntaxGroup + 'a, SyntaxStablePtr> for SyntaxStablePtrId

source§

fn lookup_intern( &self, db: &(impl Upcast<dyn SyntaxGroup + 'a> + ?Sized), ) -> SyntaxStablePtr

Implementors§

source§

impl<DB> SyntaxGroup for DB
where DB: FilesGroup + Upcast<dyn FilesGroup> + Database + HasQueryGroup<SyntaxDatabase>,