public class FilerUtils
extends java.lang.Object
Filer.| Modifier and Type | Method and Description |
|---|---|
static void |
writeCompilationUnit(javax.annotation.processing.Filer filer,
QualifiedName classToWrite,
javax.lang.model.element.Element originatingElement,
java.lang.String source)
Writes
source to the correct file for classToWrite. |
public static void writeCompilationUnit(javax.annotation.processing.Filer filer,
QualifiedName classToWrite,
javax.lang.model.element.Element originatingElement,
java.lang.String source)
throws java.io.IOException
source to the correct file for classToWrite.
This is complicated mainly by an EJC bug that returns the wrong object from
Writer.append(CharSequence), plus how to handle any exception thrown from
Writer.close().
java.io.IOException