|
The im4java Library, Version 1.4.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.im4java.script.AbstractScriptGenerator
public abstract class AbstractScriptGenerator
This class is an abstract implementation of a ScriptGenerator.
Field Summary | |
---|---|
protected char |
ESC_EOL
The EOL escape character. |
protected char |
ESC_SPECIAL
The escape character for special characters. |
protected int |
iArgIndex
The current script-argument-index. |
protected java.lang.String |
iIndent
The current indentation-level. |
protected java.lang.StringBuilder |
iLineBuffer
The current line-buffer. |
protected static int |
LINE_SIZE
The maximum linesize. |
Constructor Summary | |
---|---|
AbstractScriptGenerator()
|
Method Summary | |
---|---|
void |
createScript()
Generate the script. |
Operation |
getOperation()
Return the Operation-object. |
java.util.Properties |
getProperties()
Return the Properties-object. |
protected java.lang.String |
getScriptArg(java.lang.String pToken)
Return the token as a script-argument. |
protected java.lang.String |
getSearchPath()
Return the search-path in a plattform-dependent way. |
java.io.PrintWriter |
getWriter()
Return the PrintWriter-object. |
void |
init(java.io.PrintWriter pWriter,
Operation pOp,
java.util.Properties pProps)
Intialize the generator. |
protected java.lang.String |
quote(java.lang.String pString)
Quote the given string. |
protected void |
writeCommand()
Write the ImageCommand to the script-file. |
protected void |
writeHeader()
Write the header of the script. |
protected void |
writeOperation()
Write the Operation to the script-file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final int LINE_SIZE
protected char ESC_EOL
protected char ESC_SPECIAL
protected java.lang.String iIndent
protected java.lang.StringBuilder iLineBuffer
protected int iArgIndex
Constructor Detail |
---|
public AbstractScriptGenerator()
Method Detail |
---|
public void createScript()
createScript
in interface ScriptGenerator
protected void writeHeader()
protected java.lang.String getSearchPath()
protected void writeCommand()
protected java.lang.String getScriptArg(java.lang.String pToken)
This method must be implemented by subclasses.
protected java.lang.String quote(java.lang.String pString)
protected void writeOperation()
public void init(java.io.PrintWriter pWriter, Operation pOp, java.util.Properties pProps)
init
in interface ScriptGenerator
public java.io.PrintWriter getWriter()
public Operation getOperation()
public java.util.Properties getProperties()
|
The im4java Library, Version 1.4.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |