Package io.codemodder
Class CompositeJavaParserChanger
java.lang.Object
io.codemodder.javaparser.JavaParserChanger
io.codemodder.CompositeJavaParserChanger
- All Implemented Interfaces:
CodeChanger
A type that allows composing multiple
JavaParserChanger
instances are under the same
umbrella.
For instance, you might want to have multiple changers, each with their own SARIF collection,
all be reported under the same Codemod.id()
.
-
Field Summary
Fields inherited from class io.codemodder.javaparser.JavaParserChanger
reporter
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
CompositeJavaParserChanger
(CodemodReporterStrategy reporterStrategy, JavaParserChanger... changers) protected
CompositeJavaParserChanger
(JavaParserChanger... changers) -
Method Summary
Modifier and TypeMethodDescriptionvisit
(CodemodInvocationContext context, com.github.javaparser.ast.CompilationUnit cu) Called when a Java file, which has already been parsed into a compilation unit, is seen.Methods inherited from class io.codemodder.javaparser.JavaParserChanger
dependenciesRequired, getDescription, getIndividualChangeDescription, getReferences, getSummary
-
Constructor Details
-
CompositeJavaParserChanger
protected CompositeJavaParserChanger(CodemodReporterStrategy reporterStrategy, JavaParserChanger... changers) -
CompositeJavaParserChanger
-
-
Method Details
-
visit
public List<CodemodChange> visit(CodemodInvocationContext context, com.github.javaparser.ast.CompilationUnit cu) Description copied from class:JavaParserChanger
Called when a Java file, which has already been parsed into a compilation unit, is seen.- Specified by:
visit
in classJavaParserChanger
-