com.sdm.quasar.client.swing.ui.text
Class FormatFilterDocument

java.lang.Object
  extended byjavax.swing.text.AbstractDocument
      extended byjavax.swing.text.PlainDocument
          extended bycom.sdm.quasar.client.swing.ui.text.FormatFilterDocument
All Implemented Interfaces:
javax.swing.text.Document, java.io.Serializable

public class FormatFilterDocument
extends javax.swing.text.PlainDocument

This Document formats a text while editing with a given format.

Author:
Martin Haft
See Also:
Serialized Form

Nested Class Summary
 
Nested 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
 
Field Summary
static java.lang.String DATE
           
static java.lang.String ISBN
           
static java.lang.String TIME
           
 
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
FormatFilterDocument()
          Constructs a com.sdm.quasar.client.swing.widgets.intellidocuments.FormatFilterDocument object with no format
FormatFilterDocument(java.lang.String aFormat)
          Constructs a com.sdm.quasar.client.swing.widgets.intellidocuments.FormatFilterDocument object with the given format.
 
Method Summary
 java.lang.String getFormat()
          Gets the format property (java.lang.String) value.
 void insertString(int offset, java.lang.String str, javax.swing.text.AttributeSet attr)
           
 boolean isDoBeep()
           
 void remove(int offset, int len)
           
 void setDoBeep(boolean doBeep)
           
 void setFormat(java.lang.String format)
          Sets the format property (java.lang.String) value.
 
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, getDocumentFilter, getDocumentListeners, getDocumentProperties, getEndPosition, getLength, getListeners, getProperty, getRootElements, getStartPosition, getText, getText, getUndoableEditListeners, postRemoveUpdate, putProperty, readLock, readUnlock, removeDocumentListener, removeUndoableEditListener, render, replace, setAsynchronousLoadPriority, setDocumentFilter, setDocumentProperties, writeLock, writeUnlock
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ISBN

public static final java.lang.String ISBN
See Also:
Constant Field Values

DATE

public static final java.lang.String DATE
See Also:
Constant Field Values

TIME

public static final java.lang.String TIME
See Also:
Constant Field Values
Constructor Detail

FormatFilterDocument

public FormatFilterDocument()
Constructs a com.sdm.quasar.client.swing.widgets.intellidocuments.FormatFilterDocument object with no format


FormatFilterDocument

public FormatFilterDocument(java.lang.String aFormat)
Constructs a com.sdm.quasar.client.swing.widgets.intellidocuments.FormatFilterDocument object with the given format.

Parameters:
aFormat - the format
Method Detail

isDoBeep

public boolean isDoBeep()

setDoBeep

public void setDoBeep(boolean doBeep)

getFormat

public java.lang.String getFormat()
Gets the format property (java.lang.String) value.

Returns:
The format property value.
See Also:
setFormat(java.lang.String)

insertString

public void insertString(int offset,
                         java.lang.String str,
                         javax.swing.text.AttributeSet attr)
                  throws javax.swing.text.BadLocationException
Throws:
javax.swing.text.BadLocationException

remove

public void remove(int offset,
                   int len)
            throws javax.swing.text.BadLocationException
Throws:
javax.swing.text.BadLocationException

setFormat

public void setFormat(java.lang.String format)
Sets the format property (java.lang.String) value.

Parameters:
format - The new value for the property.
See Also:
getFormat()