org.drools.eclipse.editors.completion
Class AbstractCompletionProcessor
java.lang.Object
org.drools.eclipse.editors.completion.AbstractCompletionProcessor
- All Implemented Interfaces:
- org.eclipse.jface.text.contentassist.IContentAssistProcessor
- Direct Known Subclasses:
- DefaultCompletionProcessor
public abstract class AbstractCompletionProcessor
- extends Object
- implements org.eclipse.jface.text.contentassist.IContentAssistProcessor
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractCompletionProcessor
public AbstractCompletionProcessor(org.eclipse.ui.IEditorPart editor)
getEditor
protected org.eclipse.ui.IEditorPart getEditor()
computeCompletionProposals
public org.eclipse.jface.text.contentassist.ICompletionProposal[] computeCompletionProposals(org.eclipse.jface.text.ITextViewer viewer,
int documentOffset)
- Specified by:
computeCompletionProposals in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getCompletionProposals
protected abstract List getCompletionProposals(org.eclipse.jface.text.ITextViewer viewer,
int documentOffset)
- Returns a list of RuleCompletionProposals.
- Parameters:
viewer - documentOffset -
- Returns:
filterProposalsOnPrefix
protected static void filterProposalsOnPrefix(String prefix,
List props)
- Filter out the proposals whose content does not start with the given prefix.
readBackwards
protected String readBackwards(int documentOffset,
org.eclipse.jface.text.IDocument doc)
throws org.eclipse.jface.text.BadLocationException
- Read some text from behind the cursor position.
This provides context to both filter what is shown based
on what the user has typed in, and also to provide more information for the
list of suggestions based on context.
- Throws:
org.eclipse.jface.text.BadLocationException
getCompletionProposalAutoActivationCharacters
public char[] getCompletionProposalAutoActivationCharacters()
- Specified by:
getCompletionProposalAutoActivationCharacters in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getContextInformationAutoActivationCharacters
public char[] getContextInformationAutoActivationCharacters()
- Specified by:
getContextInformationAutoActivationCharacters in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getContextInformationValidator
public org.eclipse.jface.text.contentassist.IContextInformationValidator getContextInformationValidator()
- Specified by:
getContextInformationValidator in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
computeContextInformation
public org.eclipse.jface.text.contentassist.IContextInformation[] computeContextInformation(org.eclipse.jface.text.ITextViewer viewer,
int documentOffset)
- Specified by:
computeContextInformation in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
getErrorMessage
public String getErrorMessage()
- Specified by:
getErrorMessage in interface org.eclipse.jface.text.contentassist.IContentAssistProcessor
Copyright © 2001-2012 JBoss by Red Hat. All Rights Reserved.