|
Eclipse Platform 2.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.eclipse.jface.text.ChildDocumentManager
Manages a set of child documents for given parent documents.
A child document represents a particular range of the parent
document and is accordingly adapted to changes of the parent document.
Vice versa, the parent document is accordingly adapted to changes of
its child documents. The manager does not maintain any particular management
structure but utilizes mechanisms given by IDocument
such
as position categories and position updaters.
For internal use only.
Field Summary | |
static String |
CHILDDOCUMENTS
Name of the position categories used to keep track of the child documents offset ranges into the parent document. |
Constructor Summary | |
ChildDocumentManager()
|
Method Summary | |
IDocumentInformationMapping |
createMasterSlaveMapping(IDocument slave)
Creates a new mapping between the given slave document and its master. |
IDocument |
createSlaveDocument(IDocument master)
Creates a new slave document for the given master document. |
void |
documentAboutToBeChanged(DocumentEvent event)
The manipulation described by the document event will be performed. |
void |
documentChanged(DocumentEvent event)
The manipulation described by the document event has been performed. |
protected void |
fireDocumentEvent(boolean about,
DocumentEvent event)
Informs all child documents of the document which issued this document event. |
void |
freeSlaveDocument(IDocument slave)
Frees the given slave document. |
protected IPositionUpdater |
getChildPositionUpdater()
Returns the child position updater. |
IDocument |
getMasterDocument(IDocument slave)
Returns the master of the given slave document. |
boolean |
isSlaveDocument(IDocument document)
Method isSlaveDocument. |
void |
setAutoExpandMode(IDocument slaveDocument,
boolean autoExpand)
Sets the given document's auto expand mode. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String CHILDDOCUMENTS
Constructor Detail |
public ChildDocumentManager()
Method Detail |
protected IPositionUpdater getChildPositionUpdater()
public IDocument createSlaveDocument(IDocument master)
ISlaveDocumentManager
createSlaveDocument
in interface ISlaveDocumentManager
master
-
public void freeSlaveDocument(IDocument slave)
ISlaveDocumentManager
freeSlaveDocument
in interface ISlaveDocumentManager
slave
- public IDocumentInformationMapping createMasterSlaveMapping(IDocument slave)
ISlaveDocumentManager
createMasterSlaveMapping
in interface ISlaveDocumentManager
public IDocument getMasterDocument(IDocument slave)
ISlaveDocumentManager
getMasterDocument
in interface ISlaveDocumentManager
slave
-
public boolean isSlaveDocument(IDocument document)
ISlaveDocumentManager
isSlaveDocument
in interface ISlaveDocumentManager
document
-
protected void fireDocumentEvent(boolean about, DocumentEvent event)
about
- indicates whether the change is about to happen or alread happendevent
- the document event which will be processed to inform child documentspublic void documentChanged(DocumentEvent event)
IDocumentListener
documentChanged
in interface IDocumentListener
event
- the document event describing the document changepublic void documentAboutToBeChanged(DocumentEvent event)
IDocumentListener
documentAboutToBeChanged
in interface IDocumentListener
event
- the document event describing the document changepublic void setAutoExpandMode(IDocument slaveDocument, boolean autoExpand)
ISlaveDocumentManager
setAutoExpandMode
in interface ISlaveDocumentManager
slaveDocument
- the slave whose auto expand mode should be setautoExpand
- the mode
|
Eclipse Platform 2.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |