Package com.gargoylesoftware.base.util
Class DocumentUtil.PassthroughDocument
java.lang.Object
com.gargoylesoftware.base.util.DocumentUtil.PassthroughDocument
- All Implemented Interfaces:
Document
- Direct Known Subclasses:
DocumentUtil.LengthLimitedDocument
- Enclosing class:
DocumentUtil
A document that merely passes all requests through to another document.
This is used as the base class for the custom documents provided here.
-
Field Summary
FieldsFields inherited from interface javax.swing.text.Document
StreamDescriptionProperty, TitleProperty -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddDocumentListener(DocumentListener listener) voidaddUndoableEditListener(UndoableEditListener listener) createPosition(int offs) intgetProperty(Object key) Element[]getText(int offset, int length) voidvoidinsertString(int offset, String str, AttributeSet a) voidputProperty(Object key, Object value) voidremove(int offs, int len) voidremoveDocumentListener(DocumentListener listener) voidvoid
-
Field Details
-
delegate_
-
-
Constructor Details
-
PassthroughDocument
Create an instance- Parameters:
delegate- The document to wrap.
-
-
Method Details
-
getLength
public int getLength() -
addDocumentListener
- Specified by:
addDocumentListenerin interfaceDocument
-
removeDocumentListener
- Specified by:
removeDocumentListenerin interfaceDocument
-
addUndoableEditListener
- Specified by:
addUndoableEditListenerin interfaceDocument
-
removeUndoableEditListener
- Specified by:
removeUndoableEditListenerin interfaceDocument
-
getProperty
- Specified by:
getPropertyin interfaceDocument
-
putProperty
- Specified by:
putPropertyin interfaceDocument
-
remove
- Specified by:
removein interfaceDocument- Throws:
BadLocationException
-
insertString
- Specified by:
insertStringin interfaceDocument- Throws:
BadLocationException
-
getText
- Specified by:
getTextin interfaceDocument- Throws:
BadLocationException
-
getText
- Specified by:
getTextin interfaceDocument- Throws:
BadLocationException
-
getStartPosition
- Specified by:
getStartPositionin interfaceDocument
-
getEndPosition
- Specified by:
getEndPositionin interfaceDocument
-
createPosition
- Specified by:
createPositionin interfaceDocument- Throws:
BadLocationException
-
getRootElements
- Specified by:
getRootElementsin interfaceDocument
-
getDefaultRootElement
- Specified by:
getDefaultRootElementin interfaceDocument
-
render
-