Class ValidationTool.JarOrDirectoryOutputFileManager
java.lang.Object
javax.tools.ForwardingJavaFileManager<JavaFileManager>
com.google.web.bindery.requestfactory.apt.ValidationTool.JarOrDirectoryOutputFileManager
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
,JavaFileManager
,OptionChecker
- Enclosing class:
ValidationTool
static class ValidationTool.JarOrDirectoryOutputFileManager
extends ForwardingJavaFileManager<JavaFileManager>
A JavaFileManager that writes the class outputs into a jar file or a
directory.
-
Nested Class Summary
Nested classes/interfaces inherited from interface javax.tools.JavaFileManager
JavaFileManager.Location
-
Field Summary
Fields inherited from class javax.tools.ForwardingJavaFileManager
fileManager
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
getFileForOutput
(JavaFileManager.Location location, String packageName, String relativeName, FileObject sibling) Not expected to be called.getJavaFileForOutput
(JavaFileManager.Location location, String className, JavaFileObject.Kind kind, FileObject sibling) This method will receive generated source and class files.boolean
isSameFile
(FileObject a, FileObject b) Methods inherited from class javax.tools.ForwardingJavaFileManager
contains, flush, getClassLoader, getFileForInput, getFileForOutputForOriginatingFiles, getJavaFileForInput, getJavaFileForOutputForOriginatingFiles, getLocationForModule, getLocationForModule, getServiceLoader, handleOption, hasLocation, inferBinaryName, inferModuleName, isSupportedOption, list, listLocationsForModules
-
Constructor Details
-
JarOrDirectoryOutputFileManager
JarOrDirectoryOutputFileManager(File output, JavaFileManager fileManager)
-
-
Method Details
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceJavaFileManager
- Overrides:
close
in classForwardingJavaFileManager<JavaFileManager>
- Throws:
IOException
-
getFileForOutput
public FileObject getFileForOutput(JavaFileManager.Location location, String packageName, String relativeName, FileObject sibling) throws IOException Not expected to be called. Overridden to prevent accidental writes to disk.- Specified by:
getFileForOutput
in interfaceJavaFileManager
- Overrides:
getFileForOutput
in classForwardingJavaFileManager<JavaFileManager>
- Throws:
IOException
-
getJavaFileForOutput
public JavaFileObject getJavaFileForOutput(JavaFileManager.Location location, String className, JavaFileObject.Kind kind, FileObject sibling) throws IOException This method will receive generated source and class files.- Specified by:
getJavaFileForOutput
in interfaceJavaFileManager
- Overrides:
getJavaFileForOutput
in classForwardingJavaFileManager<JavaFileManager>
- Throws:
IOException
-
isSameFile
- Specified by:
isSameFile
in interfaceJavaFileManager
- Overrides:
isSameFile
in classForwardingJavaFileManager<JavaFileManager>
-