|
Eclipse Platform 2.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Slave documents are documents whose contents is defined in terms of a master document. Thus, slave documents usually reflect a projection of the master document. Slave documents are causally connected to the master document. This means, changes of the master document have immediate effect in the slave document and vice versa.
A slave document manager creates slave documents for given master documents. manages the life cycle of the slave documents and keeps track of the information flow between master and slave documents. The slave document manager defines the construction rules of the slave documents in terms of the master document.
Method Summary | |
IDocumentInformationMapping |
createMasterSlaveMapping(IDocument slave)
Creates a new document information mapping between the given slave document and its master document. |
IDocument |
createSlaveDocument(IDocument master)
Creates a new slave document for the given master document. |
void |
freeSlaveDocument(IDocument slave)
Frees the given slave document. |
IDocument |
getMasterDocument(IDocument slave)
Returns the master document of the given slave document or null if the
given document is unknown to this slave document manager. |
boolean |
isSlaveDocument(IDocument document)
Returns whether the given document is a slave document known to this slave document manager. |
void |
setAutoExpandMode(IDocument slave,
boolean autoExpand)
Sets the given slave document's auto expand mode. |
Method Detail |
public IDocument createSlaveDocument(IDocument master)
freeSlaveDocument
is called. The connection between the newly created slave document and the master
document is managed by this slave document manager.master
- the master documentfreeSlaveDocument(IDocument)
public void freeSlaveDocument(IDocument slave)
createSlaveDocument
.slave
- the slave document to be freedpublic IDocumentInformationMapping createMasterSlaveMapping(IDocument slave)
null
if the given document is unknown
to this slave document manager.slave
- the slave documentnull
public IDocument getMasterDocument(IDocument slave)
null
if the
given document is unknown to this slave document manager.slave
- the slave documentnull
public boolean isSlaveDocument(IDocument document)
document
- the document to be checked whether it is a slave document known to this managertrue
if the document is a slave document, false
otherwisepublic void setAutoExpandMode(IDocument slave, boolean autoExpand)
This call is without effect if the given document is unknown to this slave document manager.
slave
- the slave whose auto expand mode should be setautoExpand
- true
for auto expand, false
otherwise
|
Eclipse Platform 2.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |