public class CompletionInitializationContext
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DUMMY_IDENTIFIER
A default string that is inserted to the file before completion to guarantee that there'll always be some non-empty element there
|
static java.lang.String |
DUMMY_IDENTIFIER_TRIMMED |
static OffsetKey |
IDENTIFIER_END_OFFSET |
static OffsetKey |
SELECTION_END_OFFSET |
static OffsetKey |
START_OFFSET |
Constructor and Description |
---|
CompletionInitializationContext(Editor editor,
Caret caret,
Language language,
PsiFile file,
CompletionType completionType,
int invocationCount) |
Modifier and Type | Method and Description |
---|---|
static int |
calcStartOffset(Caret caret) |
Caret |
getCaret() |
CompletionType |
getCompletionType() |
java.lang.String |
getDummyIdentifier() |
Editor |
getEditor() |
PsiFile |
getFile() |
int |
getIdentifierEndOffset() |
int |
getInvocationCount() |
OffsetMap |
getOffsetMap() |
Language |
getPositionLanguage() |
Project |
getProject() |
int |
getReplacementOffset() |
int |
getSelectionEndOffset() |
int |
getStartOffset() |
void |
setDummyIdentifier(java.lang.String dummyIdentifier) |
void |
setReplacementOffset(int idEnd)
Mark the offset up to which the text will be deleted if a completion variant is selected using Replace character (Tab)
|
public static final OffsetKey START_OFFSET
public static final OffsetKey SELECTION_END_OFFSET
public static final OffsetKey IDENTIFIER_END_OFFSET
public static final java.lang.String DUMMY_IDENTIFIER
public static final java.lang.String DUMMY_IDENTIFIER_TRIMMED
public CompletionInitializationContext(Editor editor, Caret caret, Language language, PsiFile file, CompletionType completionType, int invocationCount)
public static int calcStartOffset(Caret caret)
public void setDummyIdentifier(java.lang.String dummyIdentifier)
public Language getPositionLanguage()
public java.lang.String getDummyIdentifier()
public Editor getEditor()
public Caret getCaret()
public CompletionType getCompletionType()
public Project getProject()
public PsiFile getFile()
public OffsetMap getOffsetMap()
public int getStartOffset()
public int getSelectionEndOffset()
public int getIdentifierEndOffset()
public int getReplacementOffset()
public int getInvocationCount()
public void setReplacementOffset(int idEnd)