| java.lang.Object org.apache.jasper.compiler.SmapStratum
SmapStratum | public class SmapStratum (Code) | | Represents the line and file mappings associated with a JSR-045
"stratum".
author: Jayson Falkner author: Shawn Bayern |
Inner Class :public static class LineInfo | |
Constructor Summary | |
public | SmapStratum(String stratumName) Constructs a new SmapStratum object for the given stratum name
(e.g., JSP). |
Method Summary | |
public void | addFile(String filename) Adds record of a new file, by filename. | public void | addFile(String filename, String filePath) Adds record of a new file, by filename and path. | public void | addLineData(int inputStartLine, String inputFileName, int inputLineCount, int outputStartLine, int outputLineIncrement) Adds complete information about a simple line mapping. | public String | getStratumName() Returns the name of the stratum. | public String | getString() Returns the given stratum as a String: a StratumSection,
followed by at least one FileSection and at least one LineSection. | public void | optimizeLineSection() | public String | toString() |
SmapStratum | public SmapStratum(String stratumName)(Code) | | Constructs a new SmapStratum object for the given stratum name
(e.g., JSP).
Parameters: stratumName - the name of the stratum (e.g., JSP) |
addFile | public void addFile(String filename)(Code) | | Adds record of a new file, by filename.
Parameters: filename - the filename to add, unqualified by path. |
addFile | public void addFile(String filename, String filePath)(Code) | | Adds record of a new file, by filename and path. The path
may be relative to a source compilation path.
Parameters: filename - the filename to add, unqualified by path Parameters: filePath - the path for the filename, potentially relativeto a source compilation path |
addLineData | public void addLineData(int inputStartLine, String inputFileName, int inputLineCount, int outputStartLine, int outputLineIncrement)(Code) | | Adds complete information about a simple line mapping. Specify
all the fields in this method; the back-end machinery takes care
of printing only those that are necessary in the final SMAP.
(My view is that fields are optional primarily for spatial efficiency,
not for programmer convenience. Could always add utility methods
later.)
Parameters: inputStartLine - starting line in the source file(SMAP InputStartLine) Parameters: inputFileName - the filepath (or name) from which the input comes(yields SMAP LineFileID) Use unqualified namescarefully, and only when they uniquely identify a file. Parameters: inputLineCount - the number of lines in the input to map(SMAP LineFileCount) Parameters: outputStartLine - starting line in the output file (SMAP OutputStartLine) Parameters: outputLineIncrement - number of output lines to map to eachinput line (SMAP OutputLineIncrement). Given thefact that the name starts with "output", I continuously havethe subconscious urge to call this fieldOutputLineExcrement. |
getStratumName | public String getStratumName()(Code) | | Returns the name of the stratum.
|
getString | public String getString()(Code) | | Returns the given stratum as a String: a StratumSection,
followed by at least one FileSection and at least one LineSection.
|
optimizeLineSection | public void optimizeLineSection()(Code) | | Combines consecutive LineInfos wherever possible
|
|
|