com.lowagie.text.rtf.field

Class RtfTableOfContents

public class RtfTableOfContents extends RtfField

The RtfTableOfContents together with multiple RtfTOCEntry objects generates a table of contents. The table of contents will display no entries in the viewing program and the user will have to update it first. A text to inform the user of this is displayed instead.

Version: $Id: RtfTableOfContents.java 2784 2007-05-24 15:43:40Z hallm $

Author: Mark Hall (mhall@edu.uni-klu.ac.at) Steffen.Stundzig (Steffen.Stundzig@smb-tec.com) Thomas Bickel (tmb99@inode.at)

Field Summary
StringdefaultText
The default text to display
static StringFIELD_INST
field inst content
Constructor Summary
RtfTableOfContents(String defaultText)
Constructs a RtfTableOfContents.
Method Summary
protected byte[]writeFieldInstContent()
Writes the field instruction content
protected voidwriteFieldInstContent(OutputStream out)
Writes the field instruction content
protected byte[]writeFieldResultContent()
Writes the field result content
protected voidwriteFieldResultContent(OutputStream out)
Writes the field result content

Field Detail

defaultText

private String defaultText
The default text to display

FIELD_INST

private static final String FIELD_INST
field inst content

Constructor Detail

RtfTableOfContents

public RtfTableOfContents(String defaultText)
Constructs a RtfTableOfContents. The default text is the text that is displayed before the user updates the table of contents

Parameters: defaultText The default text to display

Method Detail

writeFieldInstContent

protected byte[] writeFieldInstContent()

Deprecated:

Writes the field instruction content

Returns: A byte array containing with the field instructions

Throws: IOException

writeFieldInstContent

protected void writeFieldInstContent(OutputStream out)
Writes the field instruction content

writeFieldResultContent

protected byte[] writeFieldResultContent()

Deprecated:

Writes the field result content

Returns: An byte array containing the default text

Throws: IOException

writeFieldResultContent

protected void writeFieldResultContent(OutputStream out)
Writes the field result content