|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.jface.text.AbstractDocument org.eclipse.jface.text.Document org.eclipse.xtext.ui.editor.model.XtextDocument
public class XtextDocument
Nested Class Summary | |
---|---|
protected class |
XtextDocument.XtextDocumentLocker
|
Nested classes/interfaces inherited from interface org.eclipse.jface.text.IDocumentExtension |
---|
org.eclipse.jface.text.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 | |
---|---|
XtextDocument(DocumentTokenSource tokenSource,
ITextEditComposer composer)
|
Method Summary | ||
---|---|---|
void |
addModelListener(IXtextModelListener listener)
|
|
void |
addPosition(org.eclipse.jface.text.Position position)
|
|
void |
addPosition(java.lang.String category,
org.eclipse.jface.text.Position position)
|
|
void |
addXtextDocumentContentObserver(IXtextDocumentContentObserver observer)
|
|
void |
checkAndUpdateAnnotations()
|
|
protected XtextDocument.XtextDocumentLocker |
createDocumentLocker()
|
|
void |
disposeInput()
|
|
protected void |
ensureThatStateIsNotReturned(java.lang.Object exec,
IUnitOfWork<?,XtextResource> uow)
|
|
protected void |
fireDocumentChanged(org.eclipse.jface.text.DocumentEvent event)
|
|
|
getAdapter(java.lang.Class<T> adapterType)
|
|
org.eclipse.jface.text.IRegion |
getLastDamage()
|
|
org.eclipse.jface.text.Position[] |
getPositions(java.lang.String category)
|
|
org.eclipse.jface.text.Position[] |
getPositions(java.lang.String category,
int offset,
int length,
boolean canStartBefore,
boolean canEndAfter)
|
|
org.eclipse.emf.common.util.URI |
getResourceURI()
Returns the uri of the associated emf resource . |
|
java.lang.Iterable<ILexerTokenRegion> |
getTokens()
|
|
org.eclipse.core.runtime.jobs.Job |
getValidationJob()
|
|
|
internalModify(IUnitOfWork<T,XtextResource> work)
Modifies the document's semantic model without reconciling the text nor the node model. |
|
|
modify(IUnitOfWork<T,XtextResource> work)
|
|
protected void |
notifyModelListeners(XtextResource res)
|
|
|
readOnly(IUnitOfWork<T,XtextResource> work)
|
|
void |
removeModelListener(IXtextModelListener listener)
|
|
void |
removePosition(org.eclipse.jface.text.Position position)
|
|
void |
removePosition(java.lang.String category,
org.eclipse.jface.text.Position position)
|
|
void |
removeXtextDocumentContentObserver(IXtextDocumentContentObserver observer)
|
|
void |
setInput(XtextResource resource)
|
|
void |
setValidationJob(org.eclipse.core.runtime.jobs.Job validationJob)
|
|
protected
|
updateContentBeforeRead()
|
Methods inherited from class org.eclipse.jface.text.Document |
---|
isLineInformationRepairNeeded |
Methods inherited from class org.eclipse.jface.text.AbstractDocument |
---|
acceptPostNotificationReplaces, addDocumentListener, addDocumentPartitioningListener, addDocumentRewriteSessionListener, addPositionCategory, addPositionUpdater, addPrenotifiedDocumentListener, checkStateOfPartitioner, completeInitialization, computeIndexInCategory, computeIndexInPositionList, computeIndexInPositionList, computeNumberOfLines, computePartitioning, computePartitioning, containsPosition, containsPositionCategory, doFireDocumentChanged, doFireDocumentChanged, doFireDocumentChanged2, fireDocumentAboutToBeChanged, fireDocumentPartitioningChanged, fireDocumentPartitioningChanged, fireDocumentPartitioningChanged, fireRewriteSessionChanged, get, get, getActiveRewriteSession, getChar, getContentType, getContentType, getDefaultLineDelimiter, getDocumentListeners, getDocumentManagedPositions, getDocumentPartitioner, getDocumentPartitioner, getDocumentPartitioningListeners, getLegalContentTypes, getLegalContentTypes, getLegalLineDelimiters, getLength, getLineDelimiter, getLineInformation, getLineInformationOfOffset, getLineLength, getLineOffset, getLineOfOffset, getModificationStamp, getNumberOfLines, getNumberOfLines, getPartition, getPartition, getPartitionings, getPositionCategories, getPositionUpdaters, getStore, getTracker, ignorePostNotificationReplaces, insertPositionUpdater, registerPostNotificationReplace, removeDocumentListener, removeDocumentPartitioningListener, removeDocumentRewriteSessionListener, removePositionCategory, removePositionUpdater, removePrenotifiedDocumentListener, repairLineInformation, replace, replace, resumeListenerNotification, resumePostNotificationProcessing, search, set, set, setDocumentPartitioner, setDocumentPartitioner, setInitialLineDelimiter, setLineTracker, setTextStore, startRewriteSession, startRewriteSessionOnPartitioners, startSequentialRewrite, stopListenerNotification, stopPostNotificationProcessing, stopRewriteSession, stopRewriteSessionOnPartitioners, stopSequentialRewrite, updateDocumentStructures, updatePositions |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.jface.text.IDocument |
---|
addDocumentListener, addDocumentPartitioningListener, addPositionCategory, addPositionUpdater, addPrenotifiedDocumentListener, computeIndexInCategory, computeNumberOfLines, computePartitioning, containsPosition, containsPositionCategory, get, get, getChar, getContentType, getDocumentPartitioner, getLegalContentTypes, getLegalLineDelimiters, getLength, getLineDelimiter, getLineInformation, getLineInformationOfOffset, getLineLength, getLineOffset, getLineOfOffset, getNumberOfLines, getNumberOfLines, getPartition, getPositionCategories, getPositionUpdaters, insertPositionUpdater, removeDocumentListener, removeDocumentPartitioningListener, removePositionCategory, removePositionUpdater, removePrenotifiedDocumentListener, replace, search, set, setDocumentPartitioner |
Methods inherited from interface org.eclipse.jface.text.IDocumentExtension3 |
---|
computePartitioning, getContentType, getDocumentPartitioner, getLegalContentTypes, getPartition, getPartitionings, setDocumentPartitioner |
Constructor Detail |
---|
@Inject public XtextDocument(DocumentTokenSource tokenSource, ITextEditComposer composer)
Method Detail |
---|
public void setInput(XtextResource resource)
public void disposeInput()
protected XtextDocument.XtextDocumentLocker createDocumentLocker()
public <T> T readOnly(IUnitOfWork<T,XtextResource> work)
readOnly
in interface IReadAccess<XtextResource>
public <T> T modify(IUnitOfWork<T,XtextResource> work)
modify
in interface IWriteAccess<XtextResource>
public <T> T internalModify(IUnitOfWork<T,XtextResource> work)
protected void ensureThatStateIsNotReturned(java.lang.Object exec, IUnitOfWork<?,XtextResource> uow)
public void addModelListener(IXtextModelListener listener)
addModelListener
in interface IXtextDocument
public void removeModelListener(IXtextModelListener listener)
removeModelListener
in interface IXtextDocument
protected void notifyModelListeners(XtextResource res)
public void addXtextDocumentContentObserver(IXtextDocumentContentObserver observer)
addXtextDocumentContentObserver
in interface IXtextDocument
public void removeXtextDocumentContentObserver(IXtextDocumentContentObserver observer)
removeXtextDocumentContentObserver
in interface IXtextDocument
protected <T> void updateContentBeforeRead()
public void setValidationJob(org.eclipse.core.runtime.jobs.Job validationJob)
public org.eclipse.core.runtime.jobs.Job getValidationJob()
public void checkAndUpdateAnnotations()
public org.eclipse.emf.common.util.URI getResourceURI()
uri
of the associated emf resource
.
May be null if no resource is available or its uri is null
.
public <T> T getAdapter(java.lang.Class<T> adapterType)
getAdapter
in interface IXtextDocument
public org.eclipse.jface.text.Position[] getPositions(java.lang.String category, int offset, int length, boolean canStartBefore, boolean canEndAfter) throws org.eclipse.jface.text.BadPositionCategoryException
getPositions
in class org.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.BadPositionCategoryException
public org.eclipse.jface.text.Position[] getPositions(java.lang.String category) throws org.eclipse.jface.text.BadPositionCategoryException
getPositions
in interface org.eclipse.jface.text.IDocument
getPositions
in class org.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.BadPositionCategoryException
public void addPosition(org.eclipse.jface.text.Position position) throws org.eclipse.jface.text.BadLocationException
addPosition
in interface org.eclipse.jface.text.IDocument
addPosition
in class org.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.BadLocationException
public void addPosition(java.lang.String category, org.eclipse.jface.text.Position position) throws org.eclipse.jface.text.BadLocationException, org.eclipse.jface.text.BadPositionCategoryException
addPosition
in interface org.eclipse.jface.text.IDocument
addPosition
in class org.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.BadLocationException
org.eclipse.jface.text.BadPositionCategoryException
public void removePosition(org.eclipse.jface.text.Position position)
removePosition
in interface org.eclipse.jface.text.IDocument
removePosition
in class org.eclipse.jface.text.AbstractDocument
public void removePosition(java.lang.String category, org.eclipse.jface.text.Position position) throws org.eclipse.jface.text.BadPositionCategoryException
removePosition
in interface org.eclipse.jface.text.IDocument
removePosition
in class org.eclipse.jface.text.AbstractDocument
org.eclipse.jface.text.BadPositionCategoryException
protected void fireDocumentChanged(org.eclipse.jface.text.DocumentEvent event)
fireDocumentChanged
in class org.eclipse.jface.text.AbstractDocument
public org.eclipse.jface.text.IRegion getLastDamage()
public java.lang.Iterable<ILexerTokenRegion> getTokens()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |