org.eclipse.jface.viewers |
Package-level Javadoc
Provides a framework for viewers, which are model-based
content adapters for SWT widgets.
Package Specification
A viewer is a model-based adapter on an SWT widget. Each viewer has
four parts:
an input - the object that serves as the viewer's model
a widget - the SWT control through which the viewer's model is displayed
a content provider - mediates between the model and viewer
a label provider - maps model objects to displayable labels containing
text and/or an image
This package contains the viewer framework. The viewer framework is an
independent JFace module. Using it requires a knowledge of SWT, but does
not require familiarity with any of the other JFace modules. The framework
consists of abstract base classes for viewers (Viewer, StructuredViewer,
AbstractTreeViewer) together with concrete viewer classes (ListViewer,
TreeViewer,
TableViewer,
TableTreeViewer, CheckboxTreeViewer,
and CheckboxTableViewer),
and various lesser support classes. The concrete structured viewer classes
are ready-to-use and have built-in support for drag-and-drop, filtering
(IViewerFilter and ViewerFilter), and sorting (IViewerSorter
and ViewerSorter); these classes may also be subclassed further
if required.
In general terms, creating a viewer involves the following steps:
-
instantiating a viewer on some pre-existing SWT widget,
-
setting the viewer's content provider (an object implementing IContentProvider),
-
setting the viewer's label provider (an object implementing
ILabelProvider),
-
and, finally, setting the viewer's input.
Once a viewer's input is set, the viewer becomes active. As the model changes,
it is the content provider's responsibility to respond to changes to the
model by telling the viewer what to change (done by calling add and remove
methods on the viewer). An existing viewer may be retargeted by giving
it a different object as input; the viewer is responsible for informing
the content provider of these kinds of wholesale changes (IContentProvider.inputChanged).
Also, each viewer registers with its label provider for notification of
changes that would affect what the viewer displays (see ILabelProviderListener.stateChanged).
Note: None of the classes in this package maintain global state.
|
Java Source File Name | Type | Comment |
AbstractListViewer.java | Class | Abstract base class for viewers that contain lists of items (such as a combo or list). |
AbstractTableViewer.java | Class | This is a widget independent class implementors of
org.eclipse.swt.widgets.Table like widgets can use to provide a
viewer on top of their widget implementations. |
AbstractTreeViewer.java | Class | Abstract base implementation for tree-structure-oriented viewers (trees and
table trees).
Nodes in the tree can be in either an expanded or a collapsed state,
depending on whether the children on a node are visible. |
AcceptAllFilter.java | Class | Filter that accepts everything. |
ArrayContentProvider.java | Class | This implementation of IStructuredContentProvider handles
the case where the viewer input is an unchanging array or collection of elements. |
BaseLabelProvider.java | Class | |
CellEditor.java | Class | Abstract base class for cell editors. |
CellLabelProvider.java | Class | The CellLabelProvider is an abstract implementation of a label provider for
structured viewers. |
CellNavigationStrategy.java | Class | This class implementation the strategy how the table is navigated using the
keyboard. |
CheckboxCellEditor.java | Class | A cell editor that manages a checkbox.
The cell editor's value is a boolean.
This class may be instantiated; it is not intended to be subclassed.
Note that this implementation simply fakes it and does does not create
any new controls. |
CheckboxTableViewer.java | Class | A concrete viewer based on an SWT Table
control with checkboxes on each node.
This class is not intended to be subclassed outside the viewer framework. |
CheckboxTreeViewer.java | Class | A concrete tree-structured viewer based on an SWT Tree
control with checkboxes on each node.
This class is not intended to be subclassed outside the viewer framework. |
CheckStateChangedEvent.java | Class | Event object describing a change to the checked state
of a viewer element. |
ColorCellEditor.java | Class | A cell editor that manages a color field. |
ColumnLabelProvider.java | Class | |
ColumnLayoutData.java | Class | An abstract column layout data describing the information needed
(by TableLayout ) to properly lay out a table. |
ColumnPixelData.java | Class | Describes the width of a table column in pixels, and
whether the column is resizable. |
ColumnViewer.java | Class | The ColumnViewer is the abstract superclass of viewers that have columns
(e.g., AbstractTreeViewer and AbstractTableViewer). |
ColumnViewerEditor.java | Class | This is the base for all editor implementations of Viewers. |
ColumnViewerEditorActivationEvent.java | Class | |
ColumnViewerEditorActivationListener.java | Class | |
ColumnViewerEditorActivationStrategy.java | Class | This class is responsible to determine if a cell selection event is triggers
an editor activation. |
ColumnViewerEditorDeactivationEvent.java | Class | |
ColumnViewerToolTipSupport.java | Class | The ColumnViewerTooltipSupport is the class that provides tool tips for ColumnViewers. |
ColumnWeightData.java | Class | Describes the width of a table column in terms of a weight,
a minimum width, and whether the column is resizable. |
ComboBoxCellEditor.java | Class | A cell editor that presents a list of items in a combo box. |
ComboViewer.java | Class | A concrete viewer based either on an SWT Combo control or CCombo
control. |
ContentViewer.java | Class | A content viewer is a model-based adapter on a widget which accesses its
model by means of a content provider and a label provider.
A viewer's model consists of elements, represented by objects.
A viewer defines and implements generic infrastructure for handling model
input, updates, and selections in terms of elements.
Input is obtained by querying an IContentProvider which returns
elements. |
CustomHashtable.java | Class | CustomHashtable associates keys with values. |
DecoratingLabelProvider.java | Class | A decorating label provider is a label provider which combines
a nested label provider and an optional decorator. |
DecorationContext.java | Class | A concrete implementation of the
IDecorationContext interface,
suitable for instantiating. |
DecorationOverlayIcon.java | Class | A DecorationOverlayIcon is an image descriptor that can be used
to overlay decoration images on to the 4 corner quadrants of a base image.
The four quadrants are
IDecoration.TOP_LEFT ,
IDecoration.TOP_RIGHT ,
IDecoration.BOTTOM_LEFT and
IDecoration.BOTTOM_RIGHT . |
DialogCellEditor.java | Class | An abstract cell editor that uses a dialog.
Dialog cell editors usually have a label control on the left and a button on
the right. |
DoubleClickEvent.java | Class | Event object describing a double-click. |
EditingSupport.java | Class | EditingSupport is the abstract superclass of the support for cell editing. |
FocusCellHighlighter.java | Class | |
FocusCellOwnerDrawHighlighter.java | Class | |
IBaseLabelProvider.java | Interface | A label provider maps an element of the viewer's model to
an optional image and optional text string used to display
the element in the viewer's control. |
IBasicPropertyConstants.java | Interface | Predefined property names used for elements displayed in viewers. |
ICellEditorListener.java | Interface | A listener which is notified of significant events in the
life of a cell editor. |
ICellEditorValidator.java | Interface | An interface for validating a cell editor's input. |
ICellModifier.java | Interface | A cell modifier is used to access the data model from a cell
editor in an abstract way. |
ICheckable.java | Interface | Interface for objects that support elements with a checked state. |
ICheckStateListener.java | Interface | A listener which is notified of changes to the checked
state of items in checkbox viewers. |
IColorDecorator.java | Interface | The IColorDecorator is an interface for objects that return a color to
decorate either the foreground and background colors for displaying an
an object. |
IColorProvider.java | Interface | Interface to provide color representation for a given element. |
IContentProvider.java | Interface | A content provider mediates between the viewer's model
and the viewer itself. |
IDecoration.java | Interface | Defines the result of decorating an element. |
IDecorationContext.java | Interface | A decoration context provides additional information to
a label decorator. |
IDelayedLabelDecorator.java | Interface | A delayed label decorator is a label decorator that may not have a
decoration available immediately. |
IDoubleClickListener.java | Interface | A listener which is notified of double-click events on viewers. |
IElementComparer.java | Interface | This interface is used to compare elements in a viewer for equality,
and to provide the hash code for an element.
This allows the client of the viewer to specify different equality criteria
and a different hash code implementation than the
equals and hashCode implementations of the
elements themselves. |
IFilter.java | Interface | Interface for filters. |
IFontDecorator.java | Interface | The IFontDecorator is an interface for objects that return a font to
decorate an object. |
IFontProvider.java | Interface | Interface to provide font representation for a given element. |
IInputProvider.java | Interface | Interface common to all objects that provide an input. |
IInputSelectionProvider.java | Interface | Interface common to all objects that provide both an input and
a selection. |
ILabelDecorator.java | Interface | A label decorator decorates the label text and image for some element. |
ILabelProvider.java | Interface | Extends IBaseLabelProvider with the methods
to provide the text and/or image for the label of a given element. |
ILabelProviderListener.java | Interface | A listener which is notified when a label provider's state changes. |
ILazyContentProvider.java | Interface | The ILazyContentProvider is the content provider
for table viewers created using the SWT.VIRTUAL flag that
only wish to return their contents as they are queried. |
ILazyTreeContentProvider.java | Interface | The ILazyTreeContentProvider is the content provider for tree viewers created
using the SWT.VIRTUAL flag that only wish to return their contents as they
are queried. |
ILazyTreePathContentProvider.java | Interface | The ILazyTreePathContentProvider is a tree path-based content provider for
tree viewers created using the SWT.VIRTUAL flag that only wish to return
their contents as they are queried. |
ILightweightLabelDecorator.java | Interface | The ILightweightLabelDecorator is a decorator that decorates
using a prefix, suffix and overlay image rather than doing all
of the image and text management itself like an ILabelDecorator . |
IOpenListener.java | Interface | A listener which is notified of open events on viewers. |
IPostSelectionProvider.java | Interface | Selection provider extension interface to allow providers
to notify about post selection changed events. |
ISelection.java | Interface | Interface for a selection. |
ISelectionChangedListener.java | Interface | A listener which is notified when a viewer's selection changes. |
ISelectionProvider.java | Interface | Interface common to all objects that provide a selection. |
IStructuredContentProvider.java | Interface | An interface to content providers for structured viewers. |
IStructuredSelection.java | Interface | A selection containing elements. |
ITableColorProvider.java | Interface | Interface to provide color representation for a given cell within
the row for an element in a table. |
ITableFontProvider.java | Interface | The ITableFontProvider is a font provider that provides fonts to
individual cells within tables. |
ITableLabelProvider.java | Interface | Extends IBaseLabelProvider with the methods
to provide the text and/or image for each column of a given element. |
ITreeContentProvider.java | Interface | An interface to content providers for tree-structure-oriented
viewers. |
ITreePathContentProvider.java | Interface | An interface to content providers for tree-structure-oriented viewers that
provides content based on the path of elements in the tree viewer.. |
ITreePathLabelProvider.java | Interface | An extension to
ILabelProvider that is given the
path of the element being decorated, when it is available. |
ITreeSelection.java | Interface | A selection containing tree paths.
It is recommended that clients do not implement this interface but instead
use the standard implementation of this interface,
TreeSelection .
TreeSelection adds API for getting the
IElementComparer of a selection (if available). |
ITreeViewerListener.java | Interface | A listener which is notified when a tree viewer expands or collapses
a node. |
IViewerLabelProvider.java | Interface | Extends IBaseLabelProvider with the methods
to update the label for a given element. |
LabelDecorator.java | Class | The LabelDecorator is an abstract superclass of ILabelDecorators
that support IDecorationContext. |
LabelProvider.java | Class | A label provider implementation which, by default, uses an element's
toString value for its text and null for its
image. |
LabelProviderChangedEvent.java | Class | Event object describing a label provider state change. |
ListViewer.java | Class | A concrete viewer based on an SWT List control.
This class is not intended to be subclassed. |
NamedHandleObjectLabelProvider.java | Class | A label provider for instances of NamedHandlerObject , which
exposes the name as the label. |
OpenEvent.java | Class | Event object describing an open which may be generated from a
selection or default selection event. |
OwnerDrawLabelProvider.java | Class | OwnerDrawLabelProvider is an abstract implementation of a label provider that
handles custom draw. |
SelectionChangedEvent.java | Class | Event object describing a selection change. |
StructuredSelection.java | Class | A concrete implementation of the IStructuredSelection interface,
suitable for instantiating. |
StructuredViewer.java | Class | Abstract base implementation for structure-oriented viewers (trees, lists,
tables). |
SWTFocusCellManager.java | Class | This class is responsible to provide cell management base features for the
SWT-Controls
org.eclipse.swt.widgets.Table and
org.eclipse.swt.widgets.Tree . |
TableColumnViewerLabelProvider.java | Class | TableColumnViewerLabelProvider is the mapping from the table based providers
to the ViewerLabelProvider. |
TableLayout.java | Class | A layout for a table. |
TableTreeViewer.java | Class | A concrete viewer based on a SWT TableTree control.
This class is not intended to be subclassed outside the viewer framework. |
TableViewer.java | Class | A concrete viewer based on a SWT Table control.
This class is not intended to be subclassed outside the viewer framework. |
TableViewerColumn.java | Class | ViewerColumn implementation for TableViewer to enable column-specific label
providers and editing support. |
TableViewerEditor.java | Class | |
TableViewerFocusCellManager.java | Class | This class is responsible to provide the concept of cells for
Table . |
TableViewerRow.java | Class | |
TextCellEditor.java | Class | A cell editor that manages a text entry field. |
TreeColumnViewerLabelProvider.java | Class | TreeViewerLabelProvider is the ViewerLabelProvider that handles TreePaths. |
TreeExpansionEvent.java | Class | Event object describing a tree node being expanded
or collapsed. |
TreeNode.java | Class | A simple data structure that is useful for implemented tree models. |
TreeNodeContentProvider.java | Class |
A content provider that expects every element to be a TreeNode .
Most methods delegate to TreeNode . |
TreePath.java | Class | A tree path denotes a model element in a tree viewer. |
TreePathViewerSorter.java | Class | A viewer sorter that is provided extra context in the form of the path of the
parent element of the elements being sorted. |
TreeSelection.java | Class | A concrete implementation of the ITreeSelection interface,
suitable for instantiating. |
TreeViewer.java | Class | A concrete viewer based on an SWT Tree control.
This class is not intended to be subclassed outside the viewer framework. |
TreeViewerColumn.java | Class | ViewerColumn implementation for TreeViewer to enable column-specific label
providers and editing support. |
TreeViewerEditor.java | Class | |
TreeViewerFocusCellManager.java | Class | This class is responsible to provide the concept of cells for
Tree . |
TreeViewerRow.java | Class | TreeViewerRow is the Tree implementation of ViewerRow. |
Viewer.java | Class | A viewer is a model-based adapter on a widget. |
ViewerCell.java | Class | The ViewerCell is the JFace representation of a cell entry in a ViewerRow. |
ViewerColumn.java | Class | Instances of this class represent a column of a
ColumnViewer . |
ViewerComparator.java | Class | A viewer comparator is used by a
StructuredViewer to
reorder the elements provided by its content provider.
The default compare method compares elements using two steps. |
ViewerDropAdapter.java | Class | This adapter class provides generic drag-and-drop support for a viewer. |
ViewerFilter.java | Class | A viewer filter is used by a structured viewer to
extract a subset of elements provided by its content provider. |
ViewerLabel.java | Class | The ViewerLabel is the class that is passed to a viewer to handle updates of
labels. |
ViewerRow.java | Class | ViewerRow is the abstract superclass of the part that represents items in a
Table or Tree. |
ViewerSorter.java | Class | A viewer sorter is used by a
StructuredViewer to reorder the elements
provided by its content provider.
The default compare method compares elements using two steps. |
WrappedViewerLabelProvider.java | Class | The WrappedViewerLabelProvider is a label provider that allows
ILabelProvider ,
IColorProvider and
IFontProvider to
be mapped to a ColumnLabelProvider. |