All Packages Class Hierarchy This Package Previous Next Index
Class com.sdi.tools.mls.Main
java.lang.Object
|
+----com.sdi.tools.mls.Main
- public class Main
- extends Object
The Multi Line Strings with Executable Inclusions
A Java preprocessor by Brad Cox
- Version:
- 0.1
- Author:
- Brad J. Cox, Phd; bcox@virtualschool.edu
-
fileName
- The current input file name
-
in
- The current input stream
-
lineNumber
- The line number in the current input file
-
nestingLevel
- The nesting level increases with each doData() or doCode() call.
-
out
- The current output stream
-
usage
- Usage instructions
-
Main()
-
-
doCode()
- Process an even-level {{string}} by treating it as code; e.g.
-
doData(int)
- Process an odd-level {{string}} by treating it as data; e.g.
-
doStream(InputStream, PrintWriter)
- Initiate processing of an inputstream by setting the input and outputstreams,
and setting line number and nesting level to 0.
-
main(String[])
- Usage: java com.sdi.tools.mls [-d directoryName] inputFile ...
nestingLevel
private static int nestingLevel
- The nesting level increases with each doData() or doCode() call.
Even-level nestings (including the 0th) are handled by doCode().
Odd-level nestings are handled by doData().
fileName
private static String fileName
- The current input file name
lineNumber
private static int lineNumber
- The line number in the current input file
in
private static PushbackInputStream in
- The current input stream
out
private static PrintWriter out
- The current output stream
usage
private static final String usage
- Usage instructions
Main
public Main()
doCode
private static void doCode() throws Exception
- Process an even-level {{string}} by treating it as code; e.g. an executable inclusion
doData
private static void doData(int line) throws Exception
- Process an odd-level {{string}} by treating it as data; e.g. a multi-line string
doStream
public static void doStream(InputStream is,
PrintWriter os) throws Exception
- Initiate processing of an inputstream by setting the input and outputstreams,
and setting line number and nesting level to 0.
- Parameters:
- eter - InputStream is: the input stream
- eter - PrintWriter os: the output stream
main
public static void main(String args[])
- Usage: java com.sdi.tools.mls [-d directoryName] inputFile ...
All Packages Class Hierarchy This Package Previous Next Index