|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.text.AbstractDocument
javax.swing.text.PlainDocument
com.vwp.swing.text.ExtendedDocument
public class ExtendedDocument
This class implements a document object which can be used to limit the maximum amount of characters a user can enter into a input field
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.text.AbstractDocument |
|---|
javax.swing.text.AbstractDocument.AbstractElement, javax.swing.text.AbstractDocument.AttributeContext, javax.swing.text.AbstractDocument.BranchElement, javax.swing.text.AbstractDocument.Content, javax.swing.text.AbstractDocument.DefaultDocumentEvent, javax.swing.text.AbstractDocument.ElementEdit, javax.swing.text.AbstractDocument.LeafElement |
| Field Summary |
|---|
| Fields inherited from class javax.swing.text.PlainDocument |
|---|
lineLimitAttribute, tabSizeAttribute |
| Fields inherited from class javax.swing.text.AbstractDocument |
|---|
BidiElementName, ContentElementName, ElementNameAttribute, ParagraphElementName, SectionElementName |
| Fields inherited from interface javax.swing.text.Document |
|---|
StreamDescriptionProperty, TitleProperty |
| Constructor Summary | |
|---|---|
ExtendedDocument(javax.swing.text.Document document,
int numChars)
Constructs a new ExtendedDocument object |
|
ExtendedDocument(int numChars)
Constructs a new ExtendedDocument object |
|
| Method Summary | |
|---|---|
void |
insertString(int offs,
java.lang.String str,
javax.swing.text.AttributeSet a)
|
| Methods inherited from class javax.swing.text.PlainDocument |
|---|
getDefaultRootElement, getParagraphElement |
| Methods inherited from class javax.swing.text.AbstractDocument |
|---|
addDocumentListener, addUndoableEditListener, createPosition, dump, getAsynchronousLoadPriority, getBidiRootElement, getDocumentFilter, getDocumentListeners, getDocumentProperties, getEndPosition, getLength, getListeners, getProperty, getRootElements, getStartPosition, getText, getText, getUndoableEditListeners, putProperty, readLock, readUnlock, remove, removeDocumentListener, removeUndoableEditListener, render, replace, setAsynchronousLoadPriority, setDocumentFilter, setDocumentProperties |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ExtendedDocument(int numChars)
numChars - The maximum amount of characters after that all additional
input is ignored until the already stored number of characters is
decreased.
public ExtendedDocument(javax.swing.text.Document document,
int numChars)
document - A Document object to use within this ExtendedDocumentnumChars - The maximum amount of characters after that all additional
input is ignored until the already stored number of characters is
decreased.| Method Detail |
|---|
public void insertString(int offs,
java.lang.String str,
javax.swing.text.AttributeSet a)
throws javax.swing.text.BadLocationException
insertString in interface javax.swing.text.DocumentinsertString in class javax.swing.text.PlainDocumentjavax.swing.text.BadLocationException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||