public class NarrativeFragment
extends java.lang.Object
This model contains the narrative text, the line index (1 based) and the line length.
It is used by the StructuredNarrative class to get additional information of each line in the narrative.
| Constructor and Description |
|---|
NarrativeFragment(java.lang.String text)
Creates a new fragment without line index or length.
|
NarrativeFragment(java.lang.String text,
int lineIndex,
int lineLength)
Creates a new fragment.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getLineIndex()
This is the 1-based index of the line in the complete narrative.
|
int |
getLineLength()
This is the length of the complete line in the original field value before parsing.
|
java.lang.String |
getText() |
java.lang.String |
toString() |
public NarrativeFragment(java.lang.String text)
text - narrative line textpublic NarrativeFragment(java.lang.String text,
int lineIndex,
int lineLength)
text - narrative line textlineIndex - complete narrative line indexlineLength - complete line lengthpublic java.lang.String getText()
public int getLineIndex()
public int getLineLength()
public java.lang.String toString()
toString in class java.lang.Object