|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.m2m.atl.adt.ui.text.atl.AtlCompletionHelper
public class AtlCompletionHelper
The completion helper, dedicated to document parsing.
| Field Summary | |
|---|---|
static java.lang.String[] |
HIGH_LEVEL_KEYWORDS
Context indicators. |
static java.lang.String[] |
PARSING_KEYWORDS
ATL parsing triggers. |
| Constructor Summary | |
|---|---|
AtlCompletionHelper(java.lang.String text)
Creates a new helper initialized with the given text. |
|
| Method Summary | |
|---|---|
AtlModelAnalyser |
computeModelAnalyser(int offset,
java.lang.String prefix,
java.lang.String fileContext)
Computes the document part to analyze, process the analysis. |
int[] |
getElementOffsets(org.eclipse.emf.ecore.EObject element,
int baseOffset)
Compute the right offset from an element, according to the base offset of the model. |
java.lang.String |
getLastKeyWord(int offset)
Retrieves the last typed keyword. |
org.eclipse.emf.ecore.EObject |
getLocatedElement(org.eclipse.emf.ecore.EObject root,
int offset,
int modelOffset)
Search the nearest element of the given offset. |
static java.lang.String |
getLocation(org.eclipse.emf.ecore.EObject element)
Returns the element location as String. |
java.lang.String |
getText(org.eclipse.emf.ecore.EObject locatedElement,
int baseOffset)
Returns the text associated to the given element. |
static boolean |
isAtlIdentifierPart(char ch)
Checks whether the given char is an ATL identifier part or not. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String[] PARSING_KEYWORDS
public static final java.lang.String[] HIGH_LEVEL_KEYWORDS
| Constructor Detail |
|---|
public AtlCompletionHelper(java.lang.String text)
text - the text| Method Detail |
|---|
public AtlModelAnalyser computeModelAnalyser(int offset,
java.lang.String prefix,
java.lang.String fileContext)
throws org.eclipse.jface.text.BadLocationException
offset - the current offsetprefix - the current prefixfileContext - the current file context
org.eclipse.jface.text.BadLocationException
public java.lang.String getText(org.eclipse.emf.ecore.EObject locatedElement,
int baseOffset)
throws org.eclipse.jface.text.BadLocationException
locatedElement - the located elementbaseOffset - the base offset of the element model
org.eclipse.jface.text.BadLocationException
public int[] getElementOffsets(org.eclipse.emf.ecore.EObject element,
int baseOffset)
throws org.eclipse.jface.text.BadLocationException
element - the given elementbaseOffset - the base offset
org.eclipse.jface.text.BadLocationExceptionpublic static java.lang.String getLocation(org.eclipse.emf.ecore.EObject element)
element - the located element
public java.lang.String getLastKeyWord(int offset)
throws org.eclipse.jface.text.BadLocationException
offset - the current offset
org.eclipse.jface.text.BadLocationException
public org.eclipse.emf.ecore.EObject getLocatedElement(org.eclipse.emf.ecore.EObject root,
int offset,
int modelOffset)
throws org.eclipse.jface.text.BadLocationException
root - the root modeloffset - the offsetmodelOffset - the root model offset
org.eclipse.jface.text.BadLocationExceptionpublic static boolean isAtlIdentifierPart(char ch)
ch - the char
true if the given char is an ATL identifier part
|
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 | |||||||||