Cantaloop CGimlet - API Documentation, Version: 0.2.0, Date: 2002-05-13 21:30 CEST

org.cantaloop.cgimlet.lang
Class AbstractCodeWriter

java.lang.Object
  |
  +--org.cantaloop.cgimlet.lang.AbstractCodeWriter
All Implemented Interfaces:
CodeWriter
Direct Known Subclasses:
JavaClassWriter

public abstract class AbstractCodeWriter
extends java.lang.Object
implements CodeWriter

Abstract class that contains useful method for code writers.

Version:
0.2.0 ($Revision: 1.1 $)
Author:
David Leuschner, Stefan Heimann

Field Summary
protected  java.io.File m_baseDir
           
protected  java.io.File m_prettyPrintConfig
           
protected  boolean m_prettyPrinting
           
 
Constructor Summary
protected AbstractCodeWriter()
          Creates a new AbstractCodeWriter instance.
protected AbstractCodeWriter(java.io.File baseDir, boolean prettyPrinting)
          Creates a new AbstractCodeWriter instance.
 
Method Summary
 java.io.File getBaseDir()
          Get the base directory of the generated files.
 java.io.File getPrettyPrintConfiguration()
          Get the configuration file for the pretty printer.
 boolean isPrettyPrinting()
          Check if pretty printing is enabled or not.
 void setBaseDir(java.io.File f)
          Set the base directory of the generated files.
 void setPrettyPrintConfiguration(java.io.File f)
          Set the configuration file for the pretty printer.
 void setPrettyPrinting(boolean b)
          Specify if generated files should be pretty-printed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.cantaloop.cgimlet.lang.CodeWriter
write, write
 

Field Detail

m_prettyPrinting

protected boolean m_prettyPrinting

m_baseDir

protected java.io.File m_baseDir

m_prettyPrintConfig

protected java.io.File m_prettyPrintConfig
Constructor Detail

AbstractCodeWriter

protected AbstractCodeWriter()
Creates a new AbstractCodeWriter instance.

AbstractCodeWriter

protected AbstractCodeWriter(java.io.File baseDir,
                             boolean prettyPrinting)
Creates a new AbstractCodeWriter instance.
Parameters:
baseDir - the base directory for the code writer.
prettyPrinting - enable or disable pretty-printing.
Method Detail

setPrettyPrintConfiguration

public void setPrettyPrintConfiguration(java.io.File f)
Description copied from interface: CodeWriter
Set the configuration file for the pretty printer.
Specified by:
setPrettyPrintConfiguration in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Parameters:
f - a File value

getPrettyPrintConfiguration

public java.io.File getPrettyPrintConfiguration()
Description copied from interface: CodeWriter
Get the configuration file for the pretty printer.
Specified by:
getPrettyPrintConfiguration in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Returns:
a File value

setPrettyPrinting

public void setPrettyPrinting(boolean b)
Description copied from interface: CodeWriter
Specify if generated files should be pretty-printed.
Specified by:
setPrettyPrinting in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Parameters:
b - a boolean value

isPrettyPrinting

public boolean isPrettyPrinting()
Description copied from interface: CodeWriter
Check if pretty printing is enabled or not.
Specified by:
isPrettyPrinting in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Returns:
a boolean value

setBaseDir

public void setBaseDir(java.io.File f)
Description copied from interface: CodeWriter
Set the base directory of the generated files.
Specified by:
setBaseDir in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Parameters:
f - a File value

getBaseDir

public java.io.File getBaseDir()
Description copied from interface: CodeWriter
Get the base directory of the generated files.
Specified by:
getBaseDir in interface CodeWriter
Following copied from interface: org.cantaloop.cgimlet.lang.CodeWriter
Returns:
a File value

Copyright 2001, 2002 Stefan Heimann, David Leuschner. All rights reserved.