public class CompletionSupport
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static CompletionContext |
checkJavaSubClass(javax.swing.text.JTextComponent editor)
is the carot within a subclass of an identifiable Java class?
TODO: this is a proof-of-concept kludge right now, where it just looks for g.*
|
static CompletionContext |
getCompletionContext(javax.swing.text.JTextComponent editor)
get the completion context for the editor at the carot position.
|
static CompletionContext |
getCompletionContext(java.lang.String line,
int pos,
int i0,
int i1,
int i2)
Get the completion context, locating the carot within the code and
identifying it as needing a package name, variable name, function, etc.
|
public static CompletionContext checkJavaSubClass(javax.swing.text.JTextComponent editor) throws javax.swing.text.BadLocationException
editor
- javax.swing.text.BadLocationException
public static CompletionContext getCompletionContext(javax.swing.text.JTextComponent editor) throws javax.swing.text.BadLocationException
editor
- the editor component containing the script and the carot position.javax.swing.text.BadLocationException
public static CompletionContext getCompletionContext(java.lang.String line, int pos, int i0, int i1, int i2)
line
- the linepos
- the position within the linei0
- always 0 (not used)i1
- always 0 (not used)i2
- the position within the line (not used)