Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## rj.tools.util
Class DecimalNumberDocument

    java.lang.Object
      |
      +--javax.swing.text.AbstractDocument
            |
            +--javax.swing.text.PlainDocument
                  |
                  +--rj.tools.util.DecimalNumberDocument

All Implemented Interfaces:
  javax.swing.text.Document, java.io.Serializable

public class DecimalNumberDocument
extends javax.swing.text.PlainDocument

`DecimalNumberDocument` only accepts deciaml characters (0-9). This document is intendet to be used with a JTextField or similia object. `private JTextField textFied = new JTextField(new DecimalNumberDocument(), "0", 3);`

Version:
  1.0
Author:
  Ralph Jocham
See Also:
  Serialized Form

Inner classes 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`

Fields inherited from class javax.swing.text.PlainDocument
`lineLimitAttribute, tabSizeAttribute`

Fields inherited from class javax.swing.text.AbstractDocument
`BAD_LOCATION, BidiElementName, ContentElementName, ElementNameAttribute, listenerList, ParagraphElementName, SectionElementName`

Fields inherited from interface javax.swing.text.Document
`StreamDescriptionProperty, TitleProperty`

Constructor Summary
`DecimalNumberDocument()`

Method Summary
`void` | `insertString(int offs, java.lang.String str, javax.swing.text.AttributeSet a)` `insertString`

Methods inherited from class javax.swing.text.PlainDocument
`createDefaultRoot, getDefaultRootElement, getParagraphElement, insertUpdate, removeUpdate`

Methods inherited from class javax.swing.text.AbstractDocument
`addDocumentListener, addUndoableEditListener, createBranchElement, createLeafElement, createPosition, dump, fireChangedUpdate, fireInsertUpdate, fireRemoveUpdate, fireUndoableEditUpdate, getAsynchronousLoadPriority, getAttributeContext, getBidiRootElement, getContent, getCurrentWriter, getDocumentProperties, getEndPosition, getLength, getListeners, getProperty, getRootElements, getStartPosition, getText, getText, postRemoveUpdate, putProperty, readLock, readUnlock, remove, removeDocumentListener, removeUndoableEditListener, render, setAsynchronousLoadPriority, setDocumentProperties, writeLock, writeUnlock`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DecimalNumberDocument

    public DecimalNumberDocument()

Method Detail

### insertString

    public void insertString(int offs,
                             java.lang.String str,
                             javax.swing.text.AttributeSet a)
                      throws javax.swing.text.BadLocationException

  `insertString`
  Overrides:
    `insertString` in class `javax.swing.text.AbstractDocument`
  Parameters:
    `offs` - an `int` value
    `str` - a `String` value
    `a` - an `AttributeSet` value
  Throws:
    `javax.swing.text.BadLocationException` - if an error occurs
  See Also:
    `PlainDocument`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

(c) 1999-2004 by Ralph Jocham (rjocham72@netscape.net)
JCSC is released under the terms of the GNU General Public License