|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.Document
public class Document
Default document implementation. Uses a GapTextStore wrapped
inside a CopyOnWriteTextStore as text store.
The used line tracker considers the following strings as line delimiters: "\n", "\r", "\r\n".
The document is ready to use. It has a default position category for which a default position updater is installed.
Performance: The implementation should perform reasonably well for typical
source code documents. It is not designed for very large documents of a size of several
megabytes. Space-saving implementations are initially used for both the text store and the line
tracker; the first modification after a set incurs the cost to transform the
document structures to efficiently handle updates.
See GapTextStore and TreeLineTracker for algorithmic behavior of the used
document structures.
GapTextStore,
CopyOnWriteTextStore| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.eclipse.jface.text.IDocumentExtension |
|---|
IDocumentExtension.IReplace |
| Field Summary |
|---|
| Fields inherited from interface org.eclipse.jface.text.IDocument |
|---|
DEFAULT_CATEGORY, DEFAULT_CONTENT_TYPE |
| Fields inherited from interface org.eclipse.jface.text.IDocumentExtension3 |
|---|
DEFAULT_PARTITIONING |
| Fields inherited from interface org.eclipse.jface.text.IDocumentExtension4 |
|---|
UNKNOWN_MODIFICATION_STAMP |
| Constructor Summary | |
|---|---|
Document()
Creates a new empty document. |
|
Document(java.lang.String initialContent)
Creates a new document with the given initial content. |
|
| Method Summary | |
|---|---|
boolean |
isLineInformationRepairNeeded(int offset,
int length,
java.lang.String text)
Tells whether the line information of the document implementing this interface needs to be repaired. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Document()
public Document(java.lang.String initialContent)
initialContent - the document's initial content| Method Detail |
|---|
public boolean isLineInformationRepairNeeded(int offset,
int length,
java.lang.String text)
throws BadLocationException
AbstractDocument
isLineInformationRepairNeeded in interface IRepairableDocumentExtensionisLineInformationRepairNeeded in class AbstractDocumentoffset - the document offsetlength - the length of the specified rangetext - the substitution text to check
true if the line information must be repaired
BadLocationException - if the offset is invalid in this documentIRepairableDocument.repairLineInformation()
|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.