Class CheckBoxEditingSupport<T,V>
java.lang.Object
org.eclipse.jface.viewers.EditingSupport
com.amalgamasimulation.desktop.binding.editingsupports.GenericEditingSupport<T,V>
com.amalgamasimulation.desktop.binding.editingsupports.CheckBoxEditingSupport<T,V>
- Type Parameters:
T- type of row valueV- type of column value (cell value)
- Direct Known Subclasses:
EMFCheckBoxEditingSupport
Class is used to edit boolean values in a cell. When a cell is clicked, the setter function is executed
- Author:
- Ionov Ivan
-
Field Summary
Fields inherited from class com.amalgamasimulation.desktop.binding.editingsupports.GenericEditingSupport
canEditCell, parent, viewer -
Constructor Summary
ConstructorsConstructorDescriptionCheckBoxEditingSupport(org.eclipse.jface.viewers.ColumnViewer viewer, org.eclipse.swt.widgets.Composite parent) -
Method Summary
Modifier and TypeMethodDescriptionprotected org.eclipse.jface.viewers.CellEditorgetCellEditorInternal(T element) protected ObjectgetValueInternal(T element) setSelectionListener(BiConsumer<T, V> selectionListener) Set up the selectionListenersetValueExtractor(Function<T, V> valueExtractor) Set up the value Extractorprotected voidsetValueInternal(T element, V value) Methods inherited from class com.amalgamasimulation.desktop.binding.editingsupports.GenericEditingSupport
canEdit, canEditInternal, getCellEditor, getValue, initializeCellEditorValue, initializeCellEditorValueInternal, setCanEditCell, setValueMethods inherited from class org.eclipse.jface.viewers.EditingSupport
getViewer, saveCellEditorValue
-
Constructor Details
-
CheckBoxEditingSupport
public CheckBoxEditingSupport(org.eclipse.jface.viewers.ColumnViewer viewer, org.eclipse.swt.widgets.Composite parent)
-
-
Method Details
-
getCellEditorInternal
- Specified by:
getCellEditorInternalin classGenericEditingSupport<T,V>
-
getValueInternal
- Specified by:
getValueInternalin classGenericEditingSupport<T,V>
-
setValueInternal
- Specified by:
setValueInternalin classGenericEditingSupport<T,V>
-
setValueExtractor
Set up the value Extractor- Parameters:
valueExtractor- Function that returns the boolean from the container object- Returns:
- this object
-
setSelectionListener
Set up the selectionListener- Parameters:
selectionListener- function executed after click on a cell- Returns:
- this object
-