class WireCompiler
Command line interface to the Wire Java generator.
Usagejava WireCompiler --proto_path=<path>
[--java_out=<path>]
[--kotlin_out=<path>]
[--files=<protos.include>]
[--includes=<message_name>[,<message_name>...]]
[--excludes=<message_name>[,<message_name>...]]
[--quiet]
[--dry_run]
[--android]
[--android-annotations]
[--compact]
[file [file...]]
--java_out should provide the folder where the files generated by the Java code generator
should be placed. Similarly, --kotlin_out should provide the folder where the files generated
by the Kotlin code generator will be written. Only one of the two should be specified.
If the --includes flag is present, its argument must be a comma-separated list of
fully-qualified message or enum names. The output will be limited to those messages and enums
that are (transitive) dependencies of the listed names. The --excludes flag excludes types, and
takes precedence over --includes.
If the --registry_class flag is present, its argument must be a Java class name. A class with
the given name will be generated, containing a constant list of all extension classes generated
during the compile. This list is suitable for passing to Wire's constructor at runtime for
constructing its internal extension registry.
If --quiet is specified, diagnostic messages to stdout are suppressed.
The --dry_run flag causes the compile to just emit the names of the source files that would be
generated to stdout.
The --android flag will cause all messages to implement the Parcelable
interface. This implies --android-annotations as well.
The --android-annotations flag will add the Nullable annotation to optional fields.
The --compact flag will emit code that uses reflection for reading, writing, and
toString methods which are normally implemented with code generation.
val dryRun: Boolean |
|
val emitAndroid: Boolean |
|
val emitAndroidAnnotations: Boolean |
|
val emitCompact: Boolean |
|
val fs: FileSystem |
|
val javaInterop: Boolean |
|
val javaOut: String? |
|
val kotlinOut: String? |
|
val log: WireLogger |
|
val namedFilesOnly: Boolean |
|
val protoPaths: List<String> |
|
val pruningRules: PruningRules |
|
val sourceFileNames: List<String> |
fun compile(): Unit |
const val CODE_GENERATED_BY_WIRE: String |
fun forArgs(fileSystem: FileSystem = FileSystems.getDefault(), logger: WireLogger = ConsoleWireLogger(), vararg args: String): WireCompiler |
|
fun main(args: Array<String>): Unit |