Top Inners Fields Constructors Methods
io.vertx.codegen

public Class Compiler

extends Object
Class Inheritance
Imports
javax.annotation.processing.Processor, javax.tools.DiagnosticCollector, .DiagnosticListener, .JavaCompiler, .JavaFileObject, .StandardJavaFileManager, .StandardLocation, .ToolProvider, java.io.File, .FileOutputStream, .IOException, .InputStream, .PrintStream, .Writer, java.nio.file.Files, .Path, java.util.ArrayList, .Arrays, .Collections, .List, .Scanner

Author
Julien Viet

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
private File
private DiagnosticListener<JavaFileObject>
private List<String>
private Processor
private File

Constructor Summary

AccessConstructor and Description
public
Compiler(Processor processor)

public
Compiler(Processor processor, DiagnosticListener<JavaFileObject> diagnosticListener)

public

Method Summary

Modifier and TypeMethod and Description
public Compiler
addOption(String option)

public boolean
compile(Class<T>... types)

public boolean
compile(List<Class<T>> types)

public boolean
compile(File... sourceFiles)

private static File
public File
public Processor
public File
public void
setClassOutput(File classOutput)

public void
setSourceOutput(File sourceOutput)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

classOutputback to summary
private File classOutput
diagnosticListenerback to summary
private DiagnosticListener<JavaFileObject> diagnosticListener
optionsback to summary
private List<String> options
processorback to summary
private Processor processor
sourceOutputback to summary
private File sourceOutput

Constructor Detail

Compilerback to summary
public Compiler(Processor processor)
Compilerback to summary
public Compiler(Processor processor, DiagnosticListener<JavaFileObject> diagnosticListener)
Compilerback to summary
public Compiler()

Method Detail

addOptionback to summary
public Compiler addOption(String option)
compileback to summary
public boolean compile(Class<T>... types) throws Exception
compileback to summary
public boolean compile(List<Class<T>> types) throws Exception
compileback to summary
public boolean compile(File... sourceFiles) throws Exception
createTempDirback to summary
private static File createTempDir() throws IOException
getClassOutputback to summary
public File getClassOutput()
getProcessorback to summary
public Processor getProcessor()
getSourceOutputback to summary
public File getSourceOutput()
setClassOutputback to summary
public void setClassOutput(File classOutput)
setSourceOutputback to summary
public void setSourceOutput(File sourceOutput)
io.vertx.codegen back to summary

private Class Compiler.NullWriter

extends Writer
Class Inheritance

Field Summary

Inherited from java.io.Writer:
lock

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public void
close()

Implements abstract java.io.Writer.close.

Implements java.io.Closeable.close.

Closes the stream, flushing it first.

public void
flush()

Implements abstract java.io.Writer.flush.

Implements java.io.Flushable.flush.

Flushes the stream.

public void
write(char[]
Array of characters
cbuf
,
int
Offset from which to start writing characters
off
,
int
Number of characters to write
len
)

Implements abstract java.io.Writer.write.

Writes a portion of an array of characters.

Inherited from java.io.Writer:
appendappendappendnullWriterwritewritewritewrite

Constructor Detail

NullWriterback to summary
private NullWriter()

Method Detail

closeback to summary
public void close() throws IOException

Implements abstract java.io.Writer.close.

Implements java.io.Closeable.close.

Doc from java.io.Writer.close.

Closes the stream, flushing it first. Once the stream has been closed, further write() or flush() invocations will cause an IOException to be thrown. Closing a previously closed stream has no effect.

Annotations
@Override
Exceptions
IOException:
If an I/O error occurs
flushback to summary
public void flush() throws IOException

Implements abstract java.io.Writer.flush.

Implements java.io.Flushable.flush.

Doc from java.io.Writer.flush.

Flushes the stream. If the stream has saved any characters from the various write() methods in a buffer, write them immediately to their intended destination. Then, if that destination is another character or byte stream, flush it. Thus one flush() invocation will flush all the buffers in a chain of Writers and OutputStreams.

If the intended destination of this stream is an abstraction provided by the underlying operating system, for example a file, then flushing the stream guarantees only that bytes previously written to the stream are passed to the operating system for writing; it does not guarantee that they are actually written to a physical device such as a disk drive.

Annotations
@Override
Exceptions
IOException:
If an I/O error occurs
writeback to summary
public void write(char[] cbuf, int off, int len) throws IOException

Implements abstract java.io.Writer.write.

Doc from java.io.Writer.write.

Writes a portion of an array of characters.

Parameters
cbuf:char[]

Array of characters

off:int

Offset from which to start writing characters

len:int

Number of characters to write

Annotations
@Override
Exceptions
IOException:
If an I/O error occurs