FileDocCategorySizeDatePackage
TextAreaDocument.javaAPI DocJava SE 5 API1114Fri Aug 26 14:58:18 BST 2005javax.swing.text.html

TextAreaDocument

public class TextAreaDocument extends PlainDocument
TextAreaDocument extends the capabilities of the PlainDocument to store the data that is initially set in the Document. This is stored in order to enable an accurate reset of the state when a reset is requested.
author
Sunita Mani
version
1.8 12/19/03

Fields Summary
String
initialText
Constructors Summary
Methods Summary
voidreset()
Resets the model by removing all the data, and restoring it to its initial state.

	try {
	    remove(0, getLength());
	    if (initialText != null) {
		insertString(0, initialText, null);
	    }
	} catch (BadLocationException e) {
	}
    
voidstoreInitialText()
Stores the data that the model is initially loaded with.

	try {
	    initialText = getText(0, getLength());
	} catch (BadLocationException e) {
	}