public interface IFilterEditor
Modifier and Type | Method and Description |
---|---|
AutoChoices |
getAutoChoices()
Returns the autoChoices mode.
|
Comparator |
getChoicesComparator()
Returns the associated
Comparator choices comparator. |
Comparator |
getComparator()
Returns the associated
Comparator , which is never null. |
Object |
getContent()
Returns the current editor's content.
|
Set<CustomChoice> |
getCustomChoices()
Returns the current choices.
|
IFilter |
getFilter()
Returns the
IFilter associated to the editor's contentThe returned instance can then be used to enable or disable the filter and its GUI component. |
Format |
getFormat()
Returns the associated
Format . |
List<Object> |
getHistory()
Returns the current history contents
|
Look |
getLook()
Returns the current editor's look.
|
int |
getMaxHistory()
Returns the maximum history size, as defined by the user.
This is not the real maximum history size, as it depends on the max number of visible rows and whether the popup contains only history or also choices |
Class<?> |
getModelClass()
Returns the class associated to the editor on the model.
|
int |
getModelIndex()
Returns the model position associated to this editor.
|
ChoiceRenderer |
getRenderer()
Returns the associated
ChoiceRenderer . |
boolean |
isAllowedInstantVanishing()
Returns the instant filtering flag.
|
boolean |
isAutoCompletion()
Returns the auto completion flag.
|
boolean |
isEditable()
Returns the editable flag.
|
boolean |
isHidePopupOnTableUpdates()
Returns the auto hide-popup flag
|
boolean |
isIgnoreCase()
Returns the ignore case flag.
|
boolean |
isInstantFiltering()
Returns the instant filtering flag.
|
boolean |
isUserInteractionEnabled()
Returns the user interaction mode.
|
void |
resetFilter()
Resets the filter, which implies set its content to empty and reset its
history choices.
|
void |
setAllowedInstantVanishing(boolean enable)
Sets the allow instant vanishing flag.
|
void |
setAutoChoices(AutoChoices mode)
Using autoChoices, the choices displayed on the popup menu are
automatically extracted from the associated
TableModel .For editors associated to boolean or short enumerations, if AutoCompletion is not set, setting the AutoChoices automatically changes the editable flag to true, unless AutoChoices has the DISABLED value |
void |
setAutoCompletion(boolean enable)
Sets the auto completion flag.
|
void |
setChoicesComparator(Comparator comparator)
Sets the
Comparator used to sort out the choices. |
void |
setComparator(Comparator comparator)
Sets the
Comparator required to compare (and sort) instances of
the associated class in the table model.This operation sets also this operator as the choices comparator (see setChoicesComparator(Comparator) ) |
void |
setContent(Object content)
Sets the content, adapted to the editors' type.
|
void |
setCustomChoices(Set<CustomChoice> choices)
Sets the available choices, shown on the popup menu.
|
void |
setEditable(boolean enable)
Defines the editor, if text based -i.e., without associated
ChoiceRenderer , as editable: this flag means that the user can enter any
text, not being limited to the existing choices |
void |
setFormat(Format format)
Sets the
Format required by the editor to handle the user's input
when the associated class is not a StringIt is initially retrieved from the IParserModel . |
void |
setHidePopupOnTableUpdates(boolean set)
Sets the auto hide-popup flag
|
void |
setHistory(List<Object> history)
Sets the history contents.
|
void |
setIgnoreCase(boolean set)
Sets the ignore case flag.
|
void |
setInstantFiltering(boolean enable)
Sets the instant filtering flag.
|
void |
setMaxHistory(int size)
Limits the history size.
This limit is only used when the popup contains also choices. |
void |
setRenderer(ChoiceRenderer renderer)
Sets the
ChoiceRenderer for the choices / history. |
void |
setUserInteractionEnabled(boolean enable)
Enables or disables the user's interaction; if disabled, the control
is disabled but the associated filter remains in place.
|
int getModelIndex()
Class<?> getModelClass()
IFilter getFilter()
IFilter
associated to the editor's contentvoid resetFilter()
void setContent(Object content)
Object getContent()
void setAutoChoices(AutoChoices mode)
TableModel
.AutoChoices getAutoChoices()
void setCustomChoices(Set<CustomChoice> choices)
Set<CustomChoice> getCustomChoices()
void setUserInteractionEnabled(boolean enable)
boolean isUserInteractionEnabled()
void setEditable(boolean enable)
ChoiceRenderer
, as editable: this flag means that the user can enter any
text, not being limited to the existing choicesboolean isEditable()
void setIgnoreCase(boolean set)
boolean isIgnoreCase()
void setFormat(Format format)
Format
required by the editor to handle the user's input
when the associated class is not a StringIParserModel
.void setComparator(Comparator comparator)
Comparator
required to compare (and sort) instances of
the associated class in the table model.setChoicesComparator(Comparator)
)comparator
- cannot be nullComparator getComparator()
Comparator
, which is never null.void setChoicesComparator(Comparator comparator)
Comparator
used to sort out the choices. By default.
this is the same operator associated to the editor. Note that editors
associated to enumeration types are sorted by default alphabetically.comparator
- can be set to null to use alphabetic sortingsetComparator(Comparator)
Comparator getChoicesComparator()
Comparator
choices comparator.void setAutoCompletion(boolean enable)
boolean isAutoCompletion()
void setHidePopupOnTableUpdates(boolean set)
boolean isHidePopupOnTableUpdates()
void setInstantFiltering(boolean enable)
boolean isInstantFiltering()
void setAllowedInstantVanishing(boolean enable)
boolean isAllowedInstantVanishing()
void setMaxHistory(int size)
int getMaxHistory()
void setRenderer(ChoiceRenderer renderer)
ChoiceRenderer
for the choices / history.
It also affects to how the content is rendered
If not null, the content cannot be text-edited anymore
renderer
- ChoiceRenderer getRenderer()
ChoiceRenderer
.Look getLook()