org.apache.beehive.controls.runtime.generator
Class SimpleFiler

Object
  extended by SimpleFiler
All Implemented Interfaces:
Filer

public class SimpleFiler
extends Object
implements Filer

The SimpleFiler class is a very basic implementation of the com.sun.mirror.apt.Filer interface, for code generation output. This is used to enable use of Filer as a common output abstraction between the APT based code generation (which uses the built-in Filer implementation and the Reflection-based implementation (ControlGenerator), which uses SimpleFiler.

Once transition to APT is complete, then Reflection-based support (including this class) will be dropped.


Nested Class Summary
 
Nested classes/interfaces inherited from interface Filer
Filer.Location
 
Constructor Summary
SimpleFiler(File outputDir)
           
 
Method Summary
 OutputStream createBinaryFile(Filer.Location loc, String pkg, File relPath)
           
 OutputStream createClassFile(String name)
           
 PrintWriter createSourceFile(String name)
           
 PrintWriter createTextFile(Filer.Location loc, String pkg, File relPath, String charsetName)
           
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleFiler

public SimpleFiler(File outputDir)
Method Detail

createSourceFile

public PrintWriter createSourceFile(String name)
                             throws IOException
Specified by:
createSourceFile in interface Filer
Throws:
IOException

createClassFile

public OutputStream createClassFile(String name)
                             throws IOException
Specified by:
createClassFile in interface Filer
Throws:
IOException

createTextFile

public PrintWriter createTextFile(Filer.Location loc,
                                  String pkg,
                                  File relPath,
                                  String charsetName)
                           throws IOException
Specified by:
createTextFile in interface Filer
Throws:
IOException

createBinaryFile

public OutputStream createBinaryFile(Filer.Location loc,
                                     String pkg,
                                     File relPath)
                              throws IOException
Specified by:
createBinaryFile in interface Filer
Throws:
IOException