|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectau.id.jericho.lib.html.StringOutputSegment
Implements an IOutputSegment whose content is a CharSequence.
| Field Summary |
| Fields inherited from interface au.id.jericho.lib.html.IOutputSegment |
COMPARATOR |
| Constructor Summary | |
StringOutputSegment(int begin,
int end,
java.lang.CharSequence text)
Constructs a new StringOutputSegment with the specified begin and end positions and the specified content. |
|
StringOutputSegment(Segment segment,
java.lang.CharSequence text)
Constructs a new StringOutputSegment with the same span as the specified Segment. |
|
| Method Summary | |
int |
getBegin()
Returns the character position in the OutputDocument where this segment begins. |
java.lang.String |
getDebugInfo()
Returns a string representation of this object useful for debugging purposes. |
int |
getEnd()
Returns the character position in the OutputDocument where this segment ends. |
void |
output(java.io.Writer writer)
Outputs the content of this output segment to the specified Writer. |
java.lang.String |
toString()
Returns the content of this output segment as a String. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public StringOutputSegment(int begin,
int end,
java.lang.CharSequence text)
StringOutputSegment with the specified begin and end positions and the specified content.
begin - the position in the OutputDocument where this output segment begins.end - the position in the OutputDocument where this output segment ends.text - the textual content of the new output segment, or null if no content.
public StringOutputSegment(Segment segment,
java.lang.CharSequence text)
Segment.
segment - a segment defining the beginning and ending positions of the new output segment.text - the textual content of the new output segment, or null if no content.| Method Detail |
public int getBegin()
IOutputSegmentOutputDocument where this segment begins.
getBegin in interface IOutputSegmentOutputDocument where this segment begins.public int getEnd()
IOutputSegmentOutputDocument where this segment ends.
getEnd in interface IOutputSegmentOutputDocument where this segment ends.
public void output(java.io.Writer writer)
throws java.io.IOException
IOutputSegmentWriter.
output in interface IOutputSegmentwriter - the Writer to which the output is to be sent.
java.io.IOException - if an I/O exception occurs.public java.lang.String toString()
IOutputSegmentString.
Note that before version 1.5 this returned a representation of this object useful for debugging purposes,
which can now be obtained via the getDebugInfo() method.
toString in interface IOutputSegmentpublic java.lang.String getDebugInfo()
IOutputSegment
getDebugInfo in interface IOutputSegment
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||