public interface CompletionProvider
Modifier and Type | Field and Description |
---|---|
static int |
COMPLETION_ALL_QUERY_TYPE
The
int value representing the query for an all code completion. |
static int |
COMPLETION_QUERY_TYPE
The
int value representing the query for a code completion. |
static int |
DOCUMENTATION_QUERY_TYPE
The
int value representing the query for a documentation. |
static int |
TOOLTIP_QUERY_TYPE
The
int value representing the query for a tooltip hint. |
Modifier and Type | Method and Description |
---|---|
CompletionTask |
createTask(int queryType,
javax.swing.text.JTextComponent component)
Creates a task that performs a query of the given type on the given component.
|
int |
getAutoQueryTypes(javax.swing.text.JTextComponent component,
java.lang.String typedText)
Called by the code completion infrastructure to check whether a text just typed
into a text component triggers an automatic query invocation.
|
static final int COMPLETION_QUERY_TYPE
int
value representing the query for a code completion.static final int DOCUMENTATION_QUERY_TYPE
int
value representing the query for a documentation.static final int TOOLTIP_QUERY_TYPE
int
value representing the query for a tooltip hint.static final int COMPLETION_ALL_QUERY_TYPE
int
value representing the query for an all code completion.CompletionTask createTask(int queryType, javax.swing.text.JTextComponent component)
org.netbeans.spi.editor.completion.support.AsyncCompletionTask
).
queryType
- a type ot the query. It can be one of the COMPLETION_QUERY_TYPE
,
COMPLETION_ALL_QUERY_TYPE
, DOCUMENTATION_QUERY_TYPE
,
or TOOLTIP_QUERY_TYPE
(but not their combination).component
- a component on which the query is performedint getAutoQueryTypes(javax.swing.text.JTextComponent component, java.lang.String typedText)
createTask(int, JTextComponent)
.component
- a component in which typing appearedtypedText
- a typed textCOMPLETION_QUERY_TYPE
, COMPLETION_ALL_QUERY_TYPE
,
DOCUMENTATION_QUERY_TYPE
, and TOOLTIP_QUERY_TYPE
values, or zero if no query should be automatically invoked.