Trait swc_ecma_visit::VisitWith
source · pub trait VisitWith<V: ?Sized + Visit> {
// Required methods
fn visit_with(&self, v: &mut V);
fn visit_children_with(&self, v: &mut V);
}
Expand description
A utility trait implemented for ast nodes, and allow to visit them with a visitor.
Required Methods§
sourcefn visit_with(&self, v: &mut V)
fn visit_with(&self, v: &mut V)
Calls a visitor method (v.visit_xxx) with self.
sourcefn visit_children_with(&self, v: &mut V)
fn visit_children_with(&self, v: &mut V)
Visit children nodes of self with v
Implementations on Foreign Types§
source§impl<V: ?Sized + Visit> VisitWith<V> for TsNonNullExpr
impl<V: ?Sized + Visit> VisitWith<V> for TsNonNullExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsUnionType
impl<V: ?Sized + Visit> VisitWith<V> for TsUnionType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<TsTypeElement>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<TsTypeElement>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<ObjectPatProp>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<ObjectPatProp>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsType
impl<V: ?Sized + Visit> VisitWith<V> for TsType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeOperator
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeOperator
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Vec<ModuleItem>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Vec<ModuleItem>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ExportNamespaceSpecifier
impl<V: ?Sized + Visit> VisitWith<V> for ExportNamespaceSpecifier
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceBody
impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceBody
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsConstructorType
impl<V: ?Sized + Visit> VisitWith<V> for TsConstructorType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for YieldExpr
impl<V: ?Sized + Visit> VisitWith<V> for YieldExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Str
impl<V: ?Sized + Visit> VisitWith<V> for Str
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for FnDecl
impl<V: ?Sized + Visit> VisitWith<V> for FnDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsEnumDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsEnumDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Lit
impl<V: ?Sized + Visit> VisitWith<V> for Lit
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ImportSpecifier
impl<V: ?Sized + Visit> VisitWith<V> for ImportSpecifier
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<ExprOrSpread>
impl<V: ?Sized + Visit> VisitWith<V> for Option<ExprOrSpread>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsRestType
impl<V: ?Sized + Visit> VisitWith<V> for TsRestType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for RestPat
impl<V: ?Sized + Visit> VisitWith<V> for RestPat
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXAttr
impl<V: ?Sized + Visit> VisitWith<V> for JSXAttr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for MethodProp
impl<V: ?Sized + Visit> VisitWith<V> for MethodProp
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ModuleDecl
impl<V: ?Sized + Visit> VisitWith<V> for ModuleDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ArrayLit
impl<V: ?Sized + Visit> VisitWith<V> for ArrayLit
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Ident>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Ident>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ObjectLit
impl<V: ?Sized + Visit> VisitWith<V> for ObjectLit
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Str>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Str>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXOpeningFragment
impl<V: ?Sized + Visit> VisitWith<V> for JSXOpeningFragment
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ExprOrSpread
impl<V: ?Sized + Visit> VisitWith<V> for ExprOrSpread
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<JSXElementChild>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<JSXElementChild>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsConstAssertion
impl<V: ?Sized + Visit> VisitWith<V> for TsConstAssertion
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Regex
impl<V: ?Sized + Visit> VisitWith<V> for Regex
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Module
impl<V: ?Sized + Visit> VisitWith<V> for Module
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ForInStmt
impl<V: ?Sized + Visit> VisitWith<V> for ForInStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<JSXAttrValue>
impl<V: ?Sized + Visit> VisitWith<V> for Option<JSXAttrValue>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParamDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParamDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeAliasDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeAliasDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsConstructSignatureDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsConstructSignatureDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Decorator
impl<V: ?Sized + Visit> VisitWith<V> for Decorator
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for PrivateProp
impl<V: ?Sized + Visit> VisitWith<V> for PrivateProp
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Invalid
impl<V: ?Sized + Visit> VisitWith<V> for Invalid
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ReservedUnused
impl<V: ?Sized + Visit> VisitWith<V> for ReservedUnused
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ImportDefaultSpecifier
impl<V: ?Sized + Visit> VisitWith<V> for ImportDefaultSpecifier
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for VarDecl
impl<V: ?Sized + Visit> VisitWith<V> for VarDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Atom>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Atom>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for PropName
impl<V: ?Sized + Visit> VisitWith<V> for PropName
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ObjectPatProp
impl<V: ?Sized + Visit> VisitWith<V> for ObjectPatProp
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsArrayType
impl<V: ?Sized + Visit> VisitWith<V> for TsArrayType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXObject
impl<V: ?Sized + Visit> VisitWith<V> for JSXObject
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsFnParam
impl<V: ?Sized + Visit> VisitWith<V> for TsFnParam
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Stmt>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Stmt>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsConditionalType
impl<V: ?Sized + Visit> VisitWith<V> for TsConditionalType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for SuperPropExpr
impl<V: ?Sized + Visit> VisitWith<V> for SuperPropExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<TsTypeParamDecl>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<TsTypeParamDecl>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for PropOrSpread
impl<V: ?Sized + Visit> VisitWith<V> for PropOrSpread
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParam
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParam
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Expr>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Expr>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for NamedExport
impl<V: ?Sized + Visit> VisitWith<V> for NamedExport
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTupleType
impl<V: ?Sized + Visit> VisitWith<V> for TsTupleType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsParamPropParam
impl<V: ?Sized + Visit> VisitWith<V> for TsParamPropParam
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<VarDeclarator>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<VarDeclarator>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Accessibility>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Accessibility>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ReturnStmt
impl<V: ?Sized + Visit> VisitWith<V> for ReturnStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Tpl
impl<V: ?Sized + Visit> VisitWith<V> for Tpl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [TplElement]
impl<V: ?Sized + Visit> VisitWith<V> for [TplElement]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsImportEqualsDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsImportEqualsDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXOpeningElement
impl<V: ?Sized + Visit> VisitWith<V> for JSXOpeningElement
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsQualifiedName
impl<V: ?Sized + Visit> VisitWith<V> for TsQualifiedName
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ClassDecl
impl<V: ?Sized + Visit> VisitWith<V> for ClassDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Atom
impl<V: ?Sized + Visit> VisitWith<V> for Atom
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ImportDecl
impl<V: ?Sized + Visit> VisitWith<V> for ImportDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsThisTypeOrIdent
impl<V: ?Sized + Visit> VisitWith<V> for TsThisTypeOrIdent
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [ImportSpecifier]
impl<V: ?Sized + Visit> VisitWith<V> for [ImportSpecifier]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Decl
impl<V: ?Sized + Visit> VisitWith<V> for Decl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V, T> VisitWith<V> for Box<T>where
V: ?Sized + Visit,
T: 'static + VisitWith<V>,
impl<V, T> VisitWith<V> for Box<T>where V: ?Sized + Visit, T: 'static + VisitWith<V>,
source§fn visit_children_with(&self, v: &mut V)
fn visit_children_with(&self, v: &mut V)
Visit children nodes of self with v