java.lang.Object
com.google.googlejavaformat.java.Main
The main class for the Java formatter CLI.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
The main entry point for the formatter, with some number of file names to format.static void
The main method for the formatter, with some number of file names to format.static com.google.googlejavaformat.java.CommandLineOptions
processArgs
(String... args) Parses and validates command-line flags.
-
Constructor Details
-
Main
-
-
Method Details
-
main
The main method for the formatter, with some number of file names to format. We process them in parallel, but we must be careful; if multiple file names refer to the same file (which is hard to determine), we must serialize their updates.- Parameters:
args
- the command-line arguments
-
format
The main entry point for the formatter, with some number of file names to format. We process them in parallel, but we must be careful; if multiple file names refer to the same file (which is hard to determine), we must serialize their update.- Parameters:
args
- the command-line arguments- Throws:
com.google.googlejavaformat.java.UsageException
-
processArgs
public static com.google.googlejavaformat.java.CommandLineOptions processArgs(String... args) throws com.google.googlejavaformat.java.UsageException Parses and validates command-line flags.- Throws:
com.google.googlejavaformat.java.UsageException
-