Trait swc_plugin::ast::VisitWith
[−]pub trait VisitWith<V> where
V: Visit + ?Sized, {
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
fn visit_with(&self, v: &mut V)
fn visit_with(&self, v: &mut V)
Calls a visitor method (v.visit_xxx) with self.
fn 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
impl<V> VisitWith<V> for Vec<TsExprWithTypeArgs, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsExprWithTypeArgs, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [Box<TsType, Global>] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [Box<TsType, Global>] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Accessibility> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Accessibility> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [SwitchCase] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [SwitchCase] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ExprOrSpread, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ExprOrSpread, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<TsTypeParamDecl> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<TsTypeParamDecl> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ClassMember, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ClassMember, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TsTypeParam, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsTypeParam, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Box<Stmt, Global>> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Box<Stmt, Global>> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ParamOrTsParamProp] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ParamOrTsParamProp] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<VarDeclOrExpr> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<VarDeclOrExpr> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Option<ExprOrSpread>, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Option<ExprOrSpread>, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<TsNamespaceBody> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<TsNamespaceBody> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Str> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Str> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [PropOrSpread] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [PropOrSpread] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Box<Expr, Global>> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Box<Expr, Global>> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsTypeParam] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsTypeParam] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ExprOrSpread] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ExprOrSpread] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Box<TsType, Global>, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Box<TsType, Global>, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [Param] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [Param] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TplElement, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TplElement, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<ExprOrSpread> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<ExprOrSpread> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ParamOrTsParamProp, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ParamOrTsParamProp, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [Stmt] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [Stmt] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ExportSpecifier] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ExportSpecifier] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ExportSpecifier, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ExportSpecifier, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Param, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Param, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TplElement] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TplElement] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TsTypeElement, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsTypeElement, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ClassMember] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ClassMember] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<JSXAttrOrSpread, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<JSXAttrOrSpread, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Box<Expr, Global>, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Box<Expr, Global>, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ImportSpecifier, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ImportSpecifier, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsEnumMember] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsEnumMember] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsTypeElement] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsTypeElement] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [JSXAttrOrSpread] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [JSXAttrOrSpread] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Option<Pat>, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Option<Pat>, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Stmt, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Stmt, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [VarDeclarator] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [VarDeclarator] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<ModuleItem, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<ModuleItem, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ModuleItem] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ModuleItem] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsTupleElement] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsTupleElement] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<TsEntityName> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<TsEntityName> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<ModuleExportName> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<ModuleExportName> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Decorator, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Decorator, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<TruePlusMinus> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<TruePlusMinus> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsFnParam] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsFnParam] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Span> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Span> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ObjectPatProp] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ObjectPatProp] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<TsTypeAnn> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<TsTypeAnn> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<SwitchCase, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<SwitchCase, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<JSXClosingElement> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<JSXClosingElement> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [TsExprWithTypeArgs] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [TsExprWithTypeArgs] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<VarDeclarator, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<VarDeclarator, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TsFnParam, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsFnParam, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<BlockStmt> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<BlockStmt> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [ImportSpecifier] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [ImportSpecifier] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TsTupleElement, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsTupleElement, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for BigInt where
V: Visit + ?Sized,
impl<V> VisitWith<V> for BigInt where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<JSXAttrValue> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<JSXAttrValue> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Pat> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Pat> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Atom<JsWordStaticSet> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Atom<JsWordStaticSet> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<TsEnumMember, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<TsEnumMember, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<Pat, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<Pat, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<JSXElementChild, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<JSXElementChild, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Ident> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Ident> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<CatchClause> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<CatchClause> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Atom<JsWordStaticSet>> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Atom<JsWordStaticSet>> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [Box<Expr, Global>] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [Box<Expr, Global>] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<Vec<ExprOrSpread, Global>> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<Vec<ExprOrSpread, Global>> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [JSXElementChild] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [JSXElementChild] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for [Option<ExprOrSpread>] where
V: Visit + ?Sized,
impl<V> VisitWith<V> for [Option<ExprOrSpread>] where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Vec<PropOrSpread, Global> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Vec<PropOrSpread, Global> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V> VisitWith<V> for Option<ObjectLit> where
V: Visit + ?Sized,
impl<V> VisitWith<V> for Option<ObjectLit> where
V: Visit + ?Sized,
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
impl<V, T> VisitWith<V> for Box<T, Global> where
V: Visit + ?Sized,
T: 'static + VisitWith<V>,
impl<V, T> VisitWith<V> for Box<T, Global> where
V: Visit + ?Sized,
T: 'static + VisitWith<V>,
fn visit_children_with(&self, v: &mut V)
fn visit_children_with(&self, v: &mut V)
Visit children nodes of self with v