Trait FoldWith
pub trait FoldWith<V>{
// Required methods
fn fold_with(self, visitor: &mut V) -> Self;
fn fold_children_with(self, visitor: &mut V) -> Self;
}__ecma and __visit only.Expand description
A trait implemented for types that can be visited using a visitor.
Required Methods§
fn fold_children_with(self, visitor: &mut V) -> Self
fn fold_children_with(self, visitor: &mut V) -> Self
Visit children nodes of self`` with visitor`.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
§impl<V> FoldWith<V> for Option<Accessibility>
impl<V> FoldWith<V> for Option<Accessibility>
§fn fold_with(self, visitor: &mut V) -> Option<Accessibility>
fn fold_with(self, visitor: &mut V) -> Option<Accessibility>
Calls Fold::fold_opt_accessibility with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<Accessibility>
§impl<V> FoldWith<V> for Option<JSXAttrValue>
impl<V> FoldWith<V> for Option<JSXAttrValue>
§fn fold_with(self, visitor: &mut V) -> Option<JSXAttrValue>
fn fold_with(self, visitor: &mut V) -> Option<JSXAttrValue>
Calls Fold::fold_opt_jsx_attr_value with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<JSXAttrValue>
§impl<V> FoldWith<V> for Option<ModuleExportName>
impl<V> FoldWith<V> for Option<ModuleExportName>
§fn fold_with(self, visitor: &mut V) -> Option<ModuleExportName>
fn fold_with(self, visitor: &mut V) -> Option<ModuleExportName>
Calls Fold::fold_opt_module_export_name with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<ModuleExportName>
§impl<V> FoldWith<V> for Option<TruePlusMinus>
impl<V> FoldWith<V> for Option<TruePlusMinus>
§fn fold_with(self, visitor: &mut V) -> Option<TruePlusMinus>
fn fold_with(self, visitor: &mut V) -> Option<TruePlusMinus>
Calls Fold::fold_opt_true_plus_minus with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<TruePlusMinus>
§impl<V> FoldWith<V> for Option<TsEntityName>
impl<V> FoldWith<V> for Option<TsEntityName>
§fn fold_with(self, visitor: &mut V) -> Option<TsEntityName>
fn fold_with(self, visitor: &mut V) -> Option<TsEntityName>
Calls Fold::fold_opt_ts_entity_name with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<TsEntityName>
§impl<V> FoldWith<V> for Option<TsNamespaceBody>
impl<V> FoldWith<V> for Option<TsNamespaceBody>
§fn fold_with(self, visitor: &mut V) -> Option<TsNamespaceBody>
fn fold_with(self, visitor: &mut V) -> Option<TsNamespaceBody>
Calls Fold::fold_opt_ts_namespace_body with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<TsNamespaceBody>
§impl<V> FoldWith<V> for Option<VarDeclOrExpr>
impl<V> FoldWith<V> for Option<VarDeclOrExpr>
§fn fold_with(self, visitor: &mut V) -> Option<VarDeclOrExpr>
fn fold_with(self, visitor: &mut V) -> Option<VarDeclOrExpr>
Calls Fold::fold_opt_var_decl_or_expr with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<VarDeclOrExpr>
§impl<V> FoldWith<V> for Option<CatchClause>
impl<V> FoldWith<V> for Option<CatchClause>
§fn fold_with(self, visitor: &mut V) -> Option<CatchClause>
fn fold_with(self, visitor: &mut V) -> Option<CatchClause>
Calls Fold::fold_opt_catch_clause with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<CatchClause>
§impl<V> FoldWith<V> for Option<ExprOrSpread>
impl<V> FoldWith<V> for Option<ExprOrSpread>
§fn fold_with(self, visitor: &mut V) -> Option<ExprOrSpread>
fn fold_with(self, visitor: &mut V) -> Option<ExprOrSpread>
Calls Fold::fold_opt_expr_or_spread with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<ExprOrSpread>
§impl<V> FoldWith<V> for Option<JSXClosingElement>
impl<V> FoldWith<V> for Option<JSXClosingElement>
§fn fold_with(self, visitor: &mut V) -> Option<JSXClosingElement>
fn fold_with(self, visitor: &mut V) -> Option<JSXClosingElement>
Calls Fold::fold_opt_jsx_closing_element with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<JSXClosingElement>
§impl<V> FoldWith<V> for Option<TsImportCallOptions>
impl<V> FoldWith<V> for Option<TsImportCallOptions>
§fn fold_with(self, visitor: &mut V) -> Option<TsImportCallOptions>
fn fold_with(self, visitor: &mut V) -> Option<TsImportCallOptions>
Calls Fold::fold_opt_ts_import_call_options with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<TsImportCallOptions>
§impl<V> FoldWith<V> for Option<Box<TsTypeParamDecl>>
impl<V> FoldWith<V> for Option<Box<TsTypeParamDecl>>
§fn fold_with(self, visitor: &mut V) -> Option<Box<TsTypeParamDecl>>
fn fold_with(self, visitor: &mut V) -> Option<Box<TsTypeParamDecl>>
Calls Fold::fold_opt_ts_type_param_decl with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<Box<TsTypeParamDecl>>
§impl<V> FoldWith<V> for Option<Box<TsTypeParamInstantiation>>
impl<V> FoldWith<V> for Option<Box<TsTypeParamInstantiation>>
§fn fold_with(self, visitor: &mut V) -> Option<Box<TsTypeParamInstantiation>>
fn fold_with(self, visitor: &mut V) -> Option<Box<TsTypeParamInstantiation>>
Calls Fold::fold_opt_ts_type_param_instantiation with self. (Extra impl)
fn fold_children_with( self, visitor: &mut V, ) -> Option<Box<TsTypeParamInstantiation>>
§impl<V> FoldWith<V> for Option<Vec<ExprOrSpread>>
impl<V> FoldWith<V> for Option<Vec<ExprOrSpread>>
§fn fold_with(self, visitor: &mut V) -> Option<Vec<ExprOrSpread>>
fn fold_with(self, visitor: &mut V) -> Option<Vec<ExprOrSpread>>
Calls Fold::fold_opt_expr_or_spreads with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Option<Vec<ExprOrSpread>>
§impl<V> FoldWith<V> for Vec<ClassMember>
impl<V> FoldWith<V> for Vec<ClassMember>
§fn fold_with(self, visitor: &mut V) -> Vec<ClassMember>
fn fold_with(self, visitor: &mut V) -> Vec<ClassMember>
Calls Fold::fold_class_members with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ClassMember>
§impl<V> FoldWith<V> for Vec<ExportSpecifier>
impl<V> FoldWith<V> for Vec<ExportSpecifier>
§fn fold_with(self, visitor: &mut V) -> Vec<ExportSpecifier>
fn fold_with(self, visitor: &mut V) -> Vec<ExportSpecifier>
Calls Fold::fold_export_specifiers with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ExportSpecifier>
§impl<V> FoldWith<V> for Vec<ImportSpecifier>
impl<V> FoldWith<V> for Vec<ImportSpecifier>
§fn fold_with(self, visitor: &mut V) -> Vec<ImportSpecifier>
fn fold_with(self, visitor: &mut V) -> Vec<ImportSpecifier>
Calls Fold::fold_import_specifiers with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ImportSpecifier>
§impl<V> FoldWith<V> for Vec<JSXAttrOrSpread>
impl<V> FoldWith<V> for Vec<JSXAttrOrSpread>
§fn fold_with(self, visitor: &mut V) -> Vec<JSXAttrOrSpread>
fn fold_with(self, visitor: &mut V) -> Vec<JSXAttrOrSpread>
Calls Fold::fold_jsx_attr_or_spreads with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<JSXAttrOrSpread>
§impl<V> FoldWith<V> for Vec<JSXElementChild>
impl<V> FoldWith<V> for Vec<JSXElementChild>
§fn fold_with(self, visitor: &mut V) -> Vec<JSXElementChild>
fn fold_with(self, visitor: &mut V) -> Vec<JSXElementChild>
Calls Fold::fold_jsx_element_childs with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<JSXElementChild>
§impl<V> FoldWith<V> for Vec<ModuleItem>
impl<V> FoldWith<V> for Vec<ModuleItem>
§fn fold_with(self, visitor: &mut V) -> Vec<ModuleItem>
fn fold_with(self, visitor: &mut V) -> Vec<ModuleItem>
Calls Fold::fold_module_items with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ModuleItem>
§impl<V> FoldWith<V> for Vec<ObjectPatProp>
impl<V> FoldWith<V> for Vec<ObjectPatProp>
§fn fold_with(self, visitor: &mut V) -> Vec<ObjectPatProp>
fn fold_with(self, visitor: &mut V) -> Vec<ObjectPatProp>
Calls Fold::fold_object_pat_props with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ObjectPatProp>
§impl<V> FoldWith<V> for Vec<ParamOrTsParamProp>
impl<V> FoldWith<V> for Vec<ParamOrTsParamProp>
§fn fold_with(self, visitor: &mut V) -> Vec<ParamOrTsParamProp>
fn fold_with(self, visitor: &mut V) -> Vec<ParamOrTsParamProp>
Calls Fold::fold_param_or_ts_param_props with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ParamOrTsParamProp>
§impl<V> FoldWith<V> for Vec<PropOrSpread>
impl<V> FoldWith<V> for Vec<PropOrSpread>
§fn fold_with(self, visitor: &mut V) -> Vec<PropOrSpread>
fn fold_with(self, visitor: &mut V) -> Vec<PropOrSpread>
Calls Fold::fold_prop_or_spreads with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<PropOrSpread>
§impl<V> FoldWith<V> for Vec<TsTypeElement>
impl<V> FoldWith<V> for Vec<TsTypeElement>
§fn fold_with(self, visitor: &mut V) -> Vec<TsTypeElement>
fn fold_with(self, visitor: &mut V) -> Vec<TsTypeElement>
Calls Fold::fold_ts_type_elements with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TsTypeElement>
§impl<V> FoldWith<V> for Vec<Option<ExprOrSpread>>
impl<V> FoldWith<V> for Vec<Option<ExprOrSpread>>
§fn fold_with(self, visitor: &mut V) -> Vec<Option<ExprOrSpread>>
fn fold_with(self, visitor: &mut V) -> Vec<Option<ExprOrSpread>>
Calls Fold::fold_opt_vec_expr_or_spreads with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<Option<ExprOrSpread>>
§impl<V> FoldWith<V> for Vec<ExprOrSpread>
impl<V> FoldWith<V> for Vec<ExprOrSpread>
§fn fold_with(self, visitor: &mut V) -> Vec<ExprOrSpread>
fn fold_with(self, visitor: &mut V) -> Vec<ExprOrSpread>
Calls Fold::fold_expr_or_spreads with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ExprOrSpread>
§impl<V> FoldWith<V> for Vec<ImportWithItem>
impl<V> FoldWith<V> for Vec<ImportWithItem>
§fn fold_with(self, visitor: &mut V) -> Vec<ImportWithItem>
fn fold_with(self, visitor: &mut V) -> Vec<ImportWithItem>
Calls Fold::fold_import_with_items with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<ImportWithItem>
§impl<V> FoldWith<V> for Vec<SwitchCase>
impl<V> FoldWith<V> for Vec<SwitchCase>
§fn fold_with(self, visitor: &mut V) -> Vec<SwitchCase>
fn fold_with(self, visitor: &mut V) -> Vec<SwitchCase>
Calls Fold::fold_switch_cases with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<SwitchCase>
§impl<V> FoldWith<V> for Vec<TplElement>
impl<V> FoldWith<V> for Vec<TplElement>
§fn fold_with(self, visitor: &mut V) -> Vec<TplElement>
fn fold_with(self, visitor: &mut V) -> Vec<TplElement>
Calls Fold::fold_tpl_elements with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TplElement>
§impl<V> FoldWith<V> for Vec<TsEnumMember>
impl<V> FoldWith<V> for Vec<TsEnumMember>
§fn fold_with(self, visitor: &mut V) -> Vec<TsEnumMember>
fn fold_with(self, visitor: &mut V) -> Vec<TsEnumMember>
Calls Fold::fold_ts_enum_members with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TsEnumMember>
§impl<V> FoldWith<V> for Vec<TsExprWithTypeArgs>
impl<V> FoldWith<V> for Vec<TsExprWithTypeArgs>
§fn fold_with(self, visitor: &mut V) -> Vec<TsExprWithTypeArgs>
fn fold_with(self, visitor: &mut V) -> Vec<TsExprWithTypeArgs>
Calls Fold::fold_ts_expr_with_type_argss with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TsExprWithTypeArgs>
§impl<V> FoldWith<V> for Vec<TsTupleElement>
impl<V> FoldWith<V> for Vec<TsTupleElement>
§fn fold_with(self, visitor: &mut V) -> Vec<TsTupleElement>
fn fold_with(self, visitor: &mut V) -> Vec<TsTupleElement>
Calls Fold::fold_ts_tuple_elements with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TsTupleElement>
§impl<V> FoldWith<V> for Vec<TsTypeParam>
impl<V> FoldWith<V> for Vec<TsTypeParam>
§fn fold_with(self, visitor: &mut V) -> Vec<TsTypeParam>
fn fold_with(self, visitor: &mut V) -> Vec<TsTypeParam>
Calls Fold::fold_ts_type_params with self. (Extra impl)
fn fold_children_with(self, visitor: &mut V) -> Vec<TsTypeParam>
§impl<V> FoldWith<V> for Vec<VarDeclarator>
impl<V> FoldWith<V> for Vec<VarDeclarator>
§fn fold_with(self, visitor: &mut V) -> Vec<VarDeclarator>
fn fold_with(self, visitor: &mut V) -> Vec<VarDeclarator>
Calls Fold::fold_var_declarators with self. (Extra impl)