Package io.codemodder

Class Runner

java.lang.Object
io.codemodder.Runner

public final class Runner extends Object
Provides an entrypoint for CLIs built with the codemodder framework.
  • Constructor Details

    • Runner

      public Runner()
  • Method Details

    • run

      public static int run(List<Class<? extends CodeChanger>> codemods, String[] args, PrintWriter stdout, PrintWriter stderr)
      Runs the codemods with a set of customized streams.
      Parameters:
      codemods - the codemods to run
      args - the arguments to pass to the codemod runner
      stdout - alternate stdout to use, or null to use the default
      stderr - alternate stderr to use, or null to use the default
      Returns:
      the exit code of the codemodder CLI
    • run

      public static void run(List<Class<? extends CodeChanger>> codemods, String[] args)
      Runs the given codemods with CLI arguments you get from a main() method. This is the most like entry point you want to use.
      See Also: