|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.jface.text.templates.TemplateCompletionProcessor
org.eclipse.m2m.atl.adt.ui.text.atl.AtlCompletionProcessor
public class AtlCompletionProcessor
The completion processor, provides content assist.
Nested Class Summary | |
---|---|
static interface |
AtlCompletionProcessor.IATLCompletionRecorder
This interface is a non-regression utility. |
Field Summary | |
---|---|
protected org.eclipse.jface.text.contentassist.IContentAssistantExtension2 |
fContentAssistant
|
Constructor Summary | |
---|---|
AtlCompletionProcessor(org.eclipse.ui.IEditorPart editor)
Constructor. |
Method Summary | |
---|---|
void |
assistSessionEnded(org.eclipse.jface.text.contentassist.ContentAssistEvent event)
|
void |
assistSessionStarted(org.eclipse.jface.text.contentassist.ContentAssistEvent event)
|
org.eclipse.jface.text.contentassist.ICompletionProposal[] |
computeCompletionProposals(org.eclipse.jface.text.ITextViewer viewer,
org.eclipse.jface.text.IDocument document,
int offset)
Computes the ATL completion proposals from a viewer or a document. |
org.eclipse.jface.text.contentassist.ICompletionProposal[] |
computeCompletionProposals(org.eclipse.jface.text.ITextViewer refViewer,
int documentOffset)
|
org.eclipse.jface.text.contentassist.IContextInformation[] |
computeContextInformation(org.eclipse.jface.text.ITextViewer viewer,
int offset)
|
static java.lang.String |
extractPrefix(org.eclipse.jface.text.IDocument document,
int offset)
Extracts the prefix at the given offset in the given document. |
protected java.lang.String |
extractPrefix(org.eclipse.jface.text.ITextViewer viewer,
int offset)
|
char[] |
getCompletionProposalAutoActivationCharacters()
|
char[] |
getContextInformationAutoActivationCharacters()
|
org.eclipse.jface.text.contentassist.IContextInformationValidator |
getContextInformationValidator()
|
protected org.eclipse.jface.text.templates.TemplateContextType |
getContextType(org.eclipse.jface.text.ITextViewer viewer,
org.eclipse.jface.text.IRegion region)
|
java.lang.String |
getErrorMessage()
|
protected org.eclipse.swt.graphics.Image |
getImage(org.eclipse.jface.text.templates.Template template)
|
AtlSourceManager |
getSourceManager()
Returns the source manager, which contains the main ATL file model. |
protected org.eclipse.jface.text.templates.Template[] |
getTemplates(java.lang.String contextTypeId)
|
void |
orderProposalsAlphabetically(boolean order)
Reorder proposals. |
void |
restrictProposalsToMatchingCases(boolean restrict)
Tells this processor to restrict is proposals to those starting with matching cases. |
void |
restrictProposalsToVisibility(boolean restrict)
Tells this processor to restrict its proposal to those element visible in the actual invocation context. |
void |
selectionChanged(org.eclipse.jface.text.contentassist.ICompletionProposal proposal,
boolean smartToggle)
|
void |
setCompletionProposalAutoActivationCharacters(char[] activationSet)
Sets this processor's set of characters triggering the activation of the completion proposal computation. |
void |
setRecorder(AtlCompletionProcessor.IATLCompletionRecorder recorder)
|
Methods inherited from class org.eclipse.jface.text.templates.TemplateCompletionProcessor |
---|
createContext, createProposal, createProposal, getRelevance |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected org.eclipse.jface.text.contentassist.IContentAssistantExtension2 fContentAssistant
Constructor Detail |
---|
public AtlCompletionProcessor(org.eclipse.ui.IEditorPart editor)
editor
- the editor partMethod Detail |
---|
public AtlSourceManager getSourceManager()
public void setRecorder(AtlCompletionProcessor.IATLCompletionRecorder recorder)
public org.eclipse.jface.text.contentassist.ICompletionProposal[] computeCompletionProposals(org.eclipse.jface.text.ITextViewer refViewer, int documentOffset)
computeCompletionProposals
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
computeCompletionProposals
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.computeCompletionProposals(org.eclipse.jface.text.ITextViewer,
int)
public org.eclipse.jface.text.contentassist.ICompletionProposal[] computeCompletionProposals(org.eclipse.jface.text.ITextViewer viewer, org.eclipse.jface.text.IDocument document, int offset) throws org.eclipse.jface.text.BadLocationException
viewer
- the current viewerdocument
- the documentoffset
- the offset
org.eclipse.jface.text.BadLocationException
public org.eclipse.jface.text.contentassist.IContextInformation[] computeContextInformation(org.eclipse.jface.text.ITextViewer viewer, int offset)
computeContextInformation
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
computeContextInformation
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.computeContextInformation(org.eclipse.jface.text.ITextViewer,
int)
public char[] getCompletionProposalAutoActivationCharacters()
getCompletionProposalAutoActivationCharacters
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getCompletionProposalAutoActivationCharacters
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.getCompletionProposalAutoActivationCharacters()
public char[] getContextInformationAutoActivationCharacters()
getContextInformationAutoActivationCharacters
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getContextInformationAutoActivationCharacters
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.getContextInformationAutoActivationCharacters()
public org.eclipse.jface.text.contentassist.IContextInformationValidator getContextInformationValidator()
getContextInformationValidator
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getContextInformationValidator
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.getContextInformationValidator()
public void orderProposalsAlphabetically(boolean order)
order
- the order to set.public void restrictProposalsToMatchingCases(boolean restrict)
restrict
- true
if proposals should be restrictedpublic void restrictProposalsToVisibility(boolean restrict)
restrict
- true
if proposals should be restrictedpublic void setCompletionProposalAutoActivationCharacters(char[] activationSet)
activationSet
- the activation setpublic java.lang.String getErrorMessage()
getErrorMessage
in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getErrorMessage
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
IContentAssistProcessor.getErrorMessage()
protected org.eclipse.jface.text.templates.Template[] getTemplates(java.lang.String contextTypeId)
getTemplates
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
TemplateCompletionProcessor.getTemplates(java.lang.String)
protected org.eclipse.jface.text.templates.TemplateContextType getContextType(org.eclipse.jface.text.ITextViewer viewer, org.eclipse.jface.text.IRegion region)
getContextType
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
TemplateCompletionProcessor.getContextType(org.eclipse.jface.text.ITextViewer,
org.eclipse.jface.text.IRegion)
protected org.eclipse.swt.graphics.Image getImage(org.eclipse.jface.text.templates.Template template)
getImage
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
TemplateCompletionProcessor.getImage(org.eclipse.jface.text.templates.Template)
protected java.lang.String extractPrefix(org.eclipse.jface.text.ITextViewer viewer, int offset)
extractPrefix
in class org.eclipse.jface.text.templates.TemplateCompletionProcessor
TemplateCompletionProcessor.extractPrefix(org.eclipse.jface.text.ITextViewer,
int)
public static java.lang.String extractPrefix(org.eclipse.jface.text.IDocument document, int offset)
document
- the documentoffset
- the given offset
public void assistSessionStarted(org.eclipse.jface.text.contentassist.ContentAssistEvent event)
assistSessionStarted
in interface org.eclipse.jface.text.contentassist.ICompletionListener
ICompletionListener.assistSessionStarted(org.eclipse.jface.text.contentassist.ContentAssistEvent)
public void assistSessionEnded(org.eclipse.jface.text.contentassist.ContentAssistEvent event)
assistSessionEnded
in interface org.eclipse.jface.text.contentassist.ICompletionListener
ICompletionListener.assistSessionEnded(org.eclipse.jface.text.contentassist.ContentAssistEvent)
public void selectionChanged(org.eclipse.jface.text.contentassist.ICompletionProposal proposal, boolean smartToggle)
selectionChanged
in interface org.eclipse.jface.text.contentassist.ICompletionListener
ICompletionListener.selectionChanged(org.eclipse.jface.text.contentassist.ICompletionProposal,
boolean)
|
Copyright 2007 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |