Class SmapStratum.LineInfo
java.lang.Object
org.apache.jasper.compiler.SmapStratum.LineInfo
- Enclosing class:
SmapStratum
Represents a single LineSection in an SMAP, associated with a particular stratum.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintCalculates the maximum output line number covered by this mapping.Returns the current LineInfo as a String, printing all values only when appropriate (but LineInfoID if and only if it's been specified, as its necessity is sensitive to context).voidsetInputLineCount(int inputLineCount) Sets the number of consecutive input lines covered by this mapping.voidsetInputStartLine(int inputStartLine) Sets the starting line number in the input source file.voidsetLineFileID(int lineFileID) Sets lineFileID.voidsetOutputLineIncrement(int outputLineIncrement) Sets the number of output lines generated per input line.voidsetOutputStartLine(int outputStartLine) Sets the starting line number in the output generated file.toString()Returns the SMAP string representation of this line info.
-
Constructor Details
-
LineInfo
public LineInfo()Creates a new LineInfo instance with default values.
-
-
Method Details
-
setInputStartLine
public void setInputStartLine(int inputStartLine) Sets the starting line number in the input source file.- Parameters:
inputStartLine- the starting input line number (must be non-negative)
-
setOutputStartLine
public void setOutputStartLine(int outputStartLine) Sets the starting line number in the output generated file.- Parameters:
outputStartLine- the starting output line number (must be non-negative)
-
setLineFileID
public void setLineFileID(int lineFileID) Sets lineFileID. Should be called only when different from that of prior LineInfo object (in any given context) or 0 if the current LineInfo has no (logical) predecessor.LineInfowill print this file number no matter what.- Parameters:
lineFileID- The new line file ID
-
setInputLineCount
public void setInputLineCount(int inputLineCount) Sets the number of consecutive input lines covered by this mapping.- Parameters:
inputLineCount- the number of input lines (must be non-negative)
-
setOutputLineIncrement
public void setOutputLineIncrement(int outputLineIncrement) Sets the number of output lines generated per input line.- Parameters:
outputLineIncrement- the output line increment (must be non-negative)
-
getMaxOutputLineNumber
public int getMaxOutputLineNumber()Calculates the maximum output line number covered by this mapping.- Returns:
- the maximum output line number
-
getString
Returns the current LineInfo as a String, printing all values only when appropriate (but LineInfoID if and only if it's been specified, as its necessity is sensitive to context).- Returns:
- the SMAP string representation of this line info
-
toString
-