Interface EmfTablePageBuilder.FinalBuilder<V extends org.eclipse.emf.ecore.EObject>
- Type Parameters:
V- the type of the table rows
- All Superinterfaces:
ISendMessagesOnDoubleClickBuilder<EmfTablePageBuilder.FinalBuilder<V>>
- Enclosing class:
EmfTablePageBuilder
public static interface EmfTablePageBuilder.FinalBuilder<V extends org.eclipse.emf.ecore.EObject>
extends ISendMessagesOnDoubleClickBuilder<EmfTablePageBuilder.FinalBuilder<V>>
The last step: optional settings in any order, then register.
-
Method Summary
Modifier and TypeMethodDescriptionShows this page for one more tree element.checkBox()Adds check boxes to the rows.checkBox(org.eclipse.emf.ecore.EAttribute checkedFeature) Adds check boxes bound to a boolean attribute of the row.observableFeatures(org.eclipse.emf.ecore.EStructuralFeature... observableFeatures) Sets the row features that redraw the row when they change.observablePath(org.eclipse.emf.ecore.EStructuralFeature... path) Adds a path of references from the row to another object.<T extends AbstractTreeElementType>
EmfTablePage<T, V> register(AbstractPagesPart<T, ? super EmfTablePage<T, V>> part) Creates the page and registers it in the part.Adds a column with row numbers.style(int style) Sets the SWT style of the table.toolBar()Starts the setup of the toolbar above the table.virtual()Makes the table virtual: rows are created only when they are shown.Methods inherited from interface com.amalgamasimulation.desktop.ui.editor.builders.interfaces.ISendMessagesOnDoubleClickBuilder
highlightOnDoubleClick, navigateOnDoubleClick
-
Method Details
-
observableFeatures
EmfTablePageBuilder.FinalBuilder<V> observableFeatures(org.eclipse.emf.ecore.EStructuralFeature... observableFeatures) Sets the row features that redraw the row when they change. Only visible rows are updated. The list replaces the features taken from the column editors, so a column without an editor must be listed here. A new call replaces the previous list.- Parameters:
observableFeatures- features of the row object- Returns:
- this builder
-
observablePath
EmfTablePageBuilder.FinalBuilder<V> observablePath(org.eclipse.emf.ecore.EStructuralFeature... path) Adds a path of references from the row to another object. For example, observablePath(PARENT, NAME) redraws the row when the name of its parent changes. Each call adds one more path.- Parameters:
path- features from the row to the observed feature- Returns:
- this builder
-
style
Sets the SWT style of the table. The default is SWT.MULTI.- Parameters:
style- the SWT style- Returns:
- this builder
-
checkBox
EmfTablePageBuilder.FinalBuilder<V> checkBox()Adds check boxes to the rows. A handler is added in columns with addCheckedItemsChangedHandler of the table.- Returns:
- this builder
-
checkBox
Adds check boxes bound to a boolean attribute of the row. A box is checked by the attribute value, and a click changes the attribute with a command that can be undone.- Parameters:
checkedFeature- the boolean attribute of the row- Returns:
- this builder
-
virtual
EmfTablePageBuilder.FinalBuilder<V> virtual()Makes the table virtual: rows are created only when they are shown. Use it for large lists. A table with check boxes is not made virtual.- Returns:
- this builder
-
rowHeader
EmfTablePageBuilder.FinalBuilder<V> rowHeader()Adds a column with row numbers.- Returns:
- this builder
-
alsoShownFor
Shows this page for one more tree element. It can be called several times.- Parameters:
type- another tree element- Returns:
- this builder
-
toolBar
Starts the setup of the toolbar above the table. end() returns to this builder.- Returns:
- the toolbar builder
-
register
<T extends AbstractTreeElementType> EmfTablePage<T,V> register(AbstractPagesPart<T, ? super EmfTablePage<T, V>> part) Creates the page and registers it in the part. Call it once: a second call throws IllegalStateException. The returned page can be extended, for example with addColumns.- Type Parameters:
T- the type of the tree elements of the part- Parameters:
part- the part that shows the page- Returns:
- the created page
-