Package ro.sync.contentcompletion.editor
Interface InlineProposal
-
- All Known Subinterfaces:
IQuickAssistProposal<I>
,SAQuickAssistProposal
@API(type=INTERNAL, src=PUBLIC) public interface InlineProposal
Inline proposal presented inInlineProposalsWindow
.
-
-
Field Summary
Fields Modifier and Type Field Description static int
HIGH_IMPORTANCE
The item is of high importance.static int
LOW_IMPORTANCE
The item is of low importance.static int
NORMAL_IMPORTANCE
The item is of normal importance.static int
PRESENT_NORMALLY
The item is to be presented in the normal position in the list.static int
PRESENT_VERY_FIRST
The item is to be presented as the first item in the list.static int
UNRECOMMENDED_IMPORTANCE
The item is not recommended to be used.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description int
compareTo(java.lang.Object other, boolean numericSort)
Compares two items.java.lang.String
getDocumentation()
Returns optional additional information about the proposal.int
getImportance()
Gets the importance attribute of the CCItem objectint
getPresentPosition()
Used for rendering of the list only.java.lang.String
getRenderString()
Returns the string to be displayed in the list of completion proposals.java.lang.String
getStringForFilter()
Gets the string used by filters.
-
-
-
Field Detail
-
PRESENT_NORMALLY
static final int PRESENT_NORMALLY
The item is to be presented in the normal position in the list.- See Also:
- Constant Field Values
-
PRESENT_VERY_FIRST
static final int PRESENT_VERY_FIRST
The item is to be presented as the first item in the list.- See Also:
- Constant Field Values
-
UNRECOMMENDED_IMPORTANCE
static final int UNRECOMMENDED_IMPORTANCE
The item is not recommended to be used. The renderer can ignore it.- See Also:
- Constant Field Values
-
LOW_IMPORTANCE
static final int LOW_IMPORTANCE
The item is of low importance.- See Also:
- Constant Field Values
-
NORMAL_IMPORTANCE
static final int NORMAL_IMPORTANCE
The item is of normal importance.- See Also:
- Constant Field Values
-
HIGH_IMPORTANCE
static final int HIGH_IMPORTANCE
The item is of high importance.- See Also:
- Constant Field Values
-
-
Method Detail
-
getStringForFilter
java.lang.String getStringForFilter()
Gets the string used by filters.- Returns:
- The string used by filters.
-
getDocumentation
java.lang.String getDocumentation()
Returns optional additional information about the proposal. The additional information will be presented to assist the user in deciding if the selected proposal is the desired choice.- Returns:
- the additional information or
null
-
getRenderString
java.lang.String getRenderString()
Returns the string to be displayed in the list of completion proposals.- Returns:
- the string to be displayed
-
getImportance
int getImportance()
Gets the importance attribute of the CCItem object- Returns:
- The importance value
-
getPresentPosition
int getPresentPosition()
Used for rendering of the list only.- Returns:
- Returns the presentPosition.
- See Also:
PRESENT_NORMALLY
,PRESENT_VERY_FIRST
-
compareTo
int compareTo(java.lang.Object other, boolean numericSort)
Compares two items. IfnumericSort
is true the compare is done first by trying to convert the render strings to Double. If they are not numeric values then the compare is delegated to the render string. If the render string starts with '/' then it is considered to be greater than the other that does not begin with '/'. This is used for changing the order in the list.- Parameters:
other
- The item to be compared with.numericSort
- Iftrue
numeirc sort will be performed.- Returns:
- -1 if less, 0 if equal, 1 if greater.
-
-