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
Constructor Summary |
protected |
AbstractCodeWriter()
Creates a new AbstractCodeWriter instance. |
protected |
AbstractCodeWriter(java.io.File baseDir,
boolean prettyPrinting)
Creates a new AbstractCodeWriter instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
m_prettyPrinting
protected boolean m_prettyPrinting
m_baseDir
protected java.io.File m_baseDir
m_prettyPrintConfig
protected java.io.File m_prettyPrintConfig
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.
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