Class Column<T,V,R extends IColumn<T,V,R>>
java.lang.Object
com.amalgamasimulation.desktop.ui.columndescriptors.Column<T,V,R>
- All Implemented Interfaces:
IColumn<T,V, R>
- Direct Known Subclasses:
EditableColumn
Class that implements a set of functions for displaying data
- Author:
- Ionov Ivan
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected BiFunction<T, V, Accumulator<Color>> protected org.eclipse.jface.viewers.ColumnViewerprotected Comparator<T> protected List<Column.ContextMenuHandler<T, V>> protected BiConsumer<T, org.eclipse.swt.widgets.Event> protected BiFunction<T, V, Color> protected BiFunction<T, V, org.eclipse.swt.graphics.Font> protected BiFunction<T, V, String> protected BiFunction<T, V, org.eclipse.swt.graphics.Image> protected Stringprotected Stringprotected org.eclipse.swt.widgets.Compositeprotected BiFunction<T, V, Color> protected Stringprotected org.eclipse.jface.viewers.ViewerColumnprotected BooleanSupplierprotected int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddContextMenuHandler(Column.ContextMenuHandler<T, V> handler) Adds a new ContextMenuHandler to the list handlersbackgroundColor(Color color) Set color for the backgroundbackgroundColor(BiFunction<T, V, Accumulator<Color>> colorExtractor) Set function to get the color for the backgroundbackgroundColor(Function<T, Color> colorExtractor) Set function to get the color for the backgroundcomparator(Comparator<T> comparator) Add a comparator that is used to sort values in this columnfont(BiFunction<T, V, org.eclipse.swt.graphics.Font> font) Set function to get the font for the columnSet function to get the font for the columnfont(org.eclipse.swt.graphics.Font font) Set font for the columnSet color for the fontfontColor(BiFunction<T, V, Color> colorExractor) Set function to get the color for the fontSet function to get the color for the fontSet "label" for the cellformat(BiFunction<T, V, String> format) Set function to get the "label" for the cellSet function to get the "label" for the cellReturns a function to get the color for the backgroundorg.eclipse.jface.viewers.ColumnViewerReturns a ColumnViewerReturn comparator in this columnReturns a list context menu handlersBiConsumer<T, org.eclipse.swt.widgets.Event> Return the doubleClickHandlerBiFunction<T, V, org.eclipse.swt.graphics.Font> getFont()Returns a function to get the font for the columnReturns a function to get the color for the fontReturns a function to get the "label" for the cellBiFunction<T, V, org.eclipse.swt.graphics.Image> getIcon()Returns a function to get the icon for the cellgetName()Returns the column nameString will be used as a cell label if it equal nullorg.eclipse.swt.widgets.CompositeReturns a parent CompositeReturns a function to get the color for the pseudoHistogramprotected RgetThis()Returns the tool tip for this column.Returns a function that extracts a value from a row value for a columnintgetWidth()Returns the column widthicon(BiFunction<T, V, org.eclipse.swt.graphics.Image> iconExtractor) Set function to get the icon for the cellSet function to get the icon for the cellicon(org.eclipse.swt.graphics.Image icon) Set icon for the cellprotected voidbooleanReturn boolean value.nullValueText(String labelForNullValue) Set nullValueText will be used as a cell label if it equal nullpseudoHistogramColor(Color colorExtractor) Set color for the pseudoHistogrampseudoHistogramColor(BiFunction<T, V, Color> colorExtractor) Set function to get the color for the pseudoHistogrampseudoHistogramColor(Function<T, Color> colorExtractor) Set function to get the color for the pseudoHistogramremoveContextMenuHandler(Column.ContextMenuHandler<T, V> handler) Removes a previously added ContextMenuHandler from the list handlersRemove the doubleClickHandlersetDoubleClickHandler(BiConsumer<T, org.eclipse.swt.widgets.Event> doubleClickHandler) Set the double click handlervoidsetViewerColumn(org.eclipse.jface.viewers.ViewerColumn viewerColumn) Set the new ViewerColumn to the columnvisible(BooleanSupplier visibility) Set the visibility functionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.amalgamasimulation.desktop.ui.columndescriptors.IColumn
getActualWidth, getColumnIndex, getViewerColumn, getVisibleColumnIndex, headerIcon, invalidateEditors, moveable, name, tooltip, width
-
Field Details
-
columnViewer
protected org.eclipse.jface.viewers.ColumnViewer columnViewer -
parent
protected org.eclipse.swt.widgets.Composite parent -
viewerColumn
protected org.eclipse.jface.viewers.ViewerColumn viewerColumn -
name
-
width
protected int width -
toolTipText
-
labelForNullValue
-
valueExtractor
-
iconExtractor
-
backgroundColorExtractor
-
fontColorExtractor
-
pseudoHistogramColorExtractor
-
fontExtractor
-
formatValue
-
comparator
-
contextMenuHanlers
-
doubleClickHandler
-
visibility
-
-
Constructor Details
-
Column
-
-
Method Details
-
getValueExtractor
Description copied from interface:IColumnReturns a function that extracts a value from a row value for a column -
getColumnViewer
public org.eclipse.jface.viewers.ColumnViewer getColumnViewer()Description copied from interface:IColumnReturns a ColumnViewer -
getParent
public org.eclipse.swt.widgets.Composite getParent()Description copied from interface:IColumnReturns a parent Composite -
setViewerColumn
public void setViewerColumn(org.eclipse.jface.viewers.ViewerColumn viewerColumn) Description copied from interface:IColumnSet the new ViewerColumn to the column -
getName
Description copied from interface:IColumnReturns the column name -
getWidth
public int getWidth()Description copied from interface:IColumnReturns the column width -
getThis
-
addContextMenuHandler
Description copied from interface:IColumnAdds a new ContextMenuHandler to the list handlers -
removeContextMenuHandler
Description copied from interface:IColumnRemoves a previously added ContextMenuHandler from the list handlers -
getContextMenuHandlers
Description copied from interface:IColumnReturns a list context menu handlers -
setDoubleClickHandler
Description copied from interface:IColumnSet the double click handler -
removeDoubleClickHandler
Description copied from interface:IColumnRemove the doubleClickHandler -
getDoubleClickHandler
Description copied from interface:IColumnReturn the doubleClickHandler -
visible
Description copied from interface:IColumnSet the visibility function -
isVisible
public boolean isVisible()Description copied from interface:IColumnReturn boolean value. -
getToolTipText
Description copied from interface:IColumnReturns the tool tip for this column. -
getBackgroundColor
Description copied from interface:IColumnReturns a function to get the color for the background -
backgroundColor
Description copied from interface:IColumnSet color for the background -
backgroundColor
Description copied from interface:IColumnSet function to get the color for the background -
backgroundColor
Description copied from interface:IColumnSet function to get the color for the background -
getFontColor
Description copied from interface:IColumnReturns a function to get the color for the font -
fontColor
Description copied from interface:IColumnSet color for the font -
fontColor
Description copied from interface:IColumnSet function to get the color for the font -
fontColor
Description copied from interface:IColumnSet function to get the color for the font -
getFont
Description copied from interface:IColumnReturns a function to get the font for the column -
font
Description copied from interface:IColumnSet font for the column -
font
Description copied from interface:IColumnSet function to get the font for the column -
font
Description copied from interface:IColumnSet function to get the font for the column -
getPseudoHistogramColor
Description copied from interface:IColumnReturns a function to get the color for the pseudoHistogram -
pseudoHistogramColor
Description copied from interface:IColumnSet color for the pseudoHistogram -
pseudoHistogramColor
Description copied from interface:IColumnSet function to get the color for the pseudoHistogram -
pseudoHistogramColor
Description copied from interface:IColumnSet function to get the color for the pseudoHistogram -
comparator
Description copied from interface:IColumnAdd a comparator that is used to sort values in this column -
getComparator
Description copied from interface:IColumnReturn comparator in this column -
getFormat
Description copied from interface:IColumnReturns a function to get the "label" for the cell -
format
Description copied from interface:IColumnSet "label" for the cell -
format
Description copied from interface:IColumnSet function to get the "label" for the cell -
format
Description copied from interface:IColumnSet function to get the "label" for the cell -
nullValueText
Description copied from interface:IColumnSet nullValueText will be used as a cell label if it equal null -
getNullValueText
Description copied from interface:IColumnString will be used as a cell label if it equal null -
getIcon
Description copied from interface:IColumnReturns a function to get the icon for the cell -
icon
Description copied from interface:IColumnSet icon for the cell -
icon
Description copied from interface:IColumnSet function to get the icon for the cell -
icon
Description copied from interface:IColumnSet function to get the icon for the cell -
initLabelProvider
protected void initLabelProvider()
-