Package org.eclipse.emf.compare.ide.ui.internal.structuremergeviewer

# Class AbstractStructuredViewerWrapper<C extends org.eclipse.swt.widgets.Control,V extends org.eclipse.emf.compare.ide.ui.internal.structuremergeviewer.IWrappableStructuredViewer>

java.lang.Object
org.eclipse.jface.viewers.Viewer
org.eclipse.jface.viewers.ContentViewer
org.eclipse.jface.viewers.StructuredViewer
org.eclipse.emf.compare.ide.ui.internal.structuremergeviewer.AbstractStructuredViewerWrapper<C,V>

All Implemented Interfaces:
  `org.eclipse.jface.viewers.IInputProvider`, `org.eclipse.jface.viewers.IInputSelectionProvider`, `org.eclipse.jface.viewers.IPostSelectionProvider`, `org.eclipse.jface.viewers.ISelectionProvider`

Direct Known Subclasses:
  `EMFCompareStructureMergeViewer`

public abstract class AbstractStructuredViewerWrapper<C extends org.eclipse.swt.widgets.Control,V extends org.eclipse.emf.compare.ide.ui.internal.structuremergeviewer.IWrappableStructuredViewer> extends org.eclipse.jface.viewers.StructuredViewer

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static final class`
`AbstractStructuredViewerWrapper.ControlAndViewer<C extends org.eclipse.swt.widgets.Control,V extends org.eclipse.emf.compare.ide.ui.internal.structuremergeviewer.IWrappableStructuredViewer>`

## Nested classes/interfaces inherited from class org.eclipse.jface.viewers.StructuredViewer

`org.eclipse.jface.viewers.StructuredViewer.ColorAndFontCollector, org.eclipse.jface.viewers.StructuredViewer.ColorAndFontCollectorWithProviders`

## Field Summary

### Fields inherited from class org.eclipse.jface.viewers.Viewer

`WIDGET_DATA_KEY`

## Constructor Summary

Constructors
Constructor
Description
`AbstractStructuredViewerWrapper(org.eclipse.swt.widgets.Composite parent, EMFCompareConfiguration compareConfiguration)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`final void`
`addDragSupport(int operations, org.eclipse.swt.dnd.Transfer[] transferTypes, org.eclipse.swt.dnd.DragSourceListener listener)`
`final void`
`addDropSupport(int operations, org.eclipse.swt.dnd.Transfer[] transferTypes, org.eclipse.swt.dnd.DropTargetListener listener)`
`final void`
`addFilter(org.eclipse.jface.viewers.ViewerFilter filter)`
`protected abstract AbstractStructuredViewerWrapper.ControlAndViewer<C,V>`
`createControlAndViewer(org.eclipse.swt.widgets.Composite parent)`
Should call `#setViewer(org.eclipse.jface.viewers.Viewer)`.
`protected final org.eclipse.swt.widgets.Widget`
`doFindInputItem(Object element)`
`protected final org.eclipse.swt.widgets.Widget`
`doFindItem(Object element)`
`protected final void`
`doUpdateItem(org.eclipse.swt.widgets.Widget item, Object element, boolean fullMap)`
`final org.eclipse.jface.viewers.ViewerComparator`
`getComparator()`
`protected final EMFCompareConfiguration`
`getCompareConfiguration()`
Get the compare configuration object.
`final org.eclipse.jface.viewers.IElementComparer`
`getComparer()`
`final C`
`getControl()`
`final org.eclipse.jface.viewers.ViewerFilter[]`
`getFilters()`
`protected final List`
`getSelectionFromWidget()`
`final org.eclipse.jface.viewers.ViewerSorter`
`getSorter()`
`protected final V`
`getViewer()`
Returns the `StructuredViewer` associated with this wrapper.
`protected void`
`handleDispose(org.eclipse.swt.events.DisposeEvent event)`
`protected final void`
`handleInvalidSelection(org.eclipse.jface.viewers.ISelection invalidSelection, org.eclipse.jface.viewers.ISelection newSelection)`
`protected void`
`preHookCreateControlAndViewer()`
`final void`
`removeFilter(org.eclipse.jface.viewers.ViewerFilter filter)`
`final void`
`resetFilters()`
`final void`
`reveal(Object element)`
`final void`
`setComparator(org.eclipse.jface.viewers.ViewerComparator comparator)`
`final void`
`setComparer(org.eclipse.jface.viewers.IElementComparer comparer)`
`final void`
`setContentProvider(org.eclipse.jface.viewers.IContentProvider provider)`
`final void`
`setFilters(org.eclipse.jface.viewers.ViewerFilter[] filters)`
`final void`
`setLabelProvider(org.eclipse.jface.viewers.IBaseLabelProvider labelProvider)`
`protected final void`
`setSelectionToWidget(List l, boolean reveal)`
`final void`
`setSorter(org.eclipse.jface.viewers.ViewerSorter sorter)`
`final void`
`setUseHashlookup(boolean enable)`

### Methods inherited from class org.eclipse.jface.viewers.StructuredViewer

`addDoubleClickListener, addOpenListener, addPostSelectionChangedListener, assertContentProviderType, assertElementsNotNull, associate, buildLabel, disassociate, equals, filter, findItem, findItems, fireDoubleClick, fireOpen, firePostSelectionChanged, getColorAndFontCollector, getFilteredChildren, getItem, getRawChildren, getRoot, getSelection, getSortedChildren, getStructuredSelection, handleDoubleSelect, handleLabelProviderChanged, handleOpen, handlePostSelect, handleSelect, hasFilters, hookControl, internalRefresh, internalRefresh, internalUpdate, mapElement, needsRefilter, preservingSelection, refresh, refresh, refresh, refresh, refreshItem, removeDoubleClickListener, removeOpenListener, removePostSelectionChangedListener, setInput, setSelection, setSelectionToWidget, testFindItem, testFindItems, unmapAllElements, unmapElement, unmapElement, update, update, updateItem, updateSelection, usingElementMap`

### Methods inherited from class org.eclipse.jface.viewers.ContentViewer

`getContentProvider, getInput, getLabelProvider, labelProviderChanged`

### Methods inherited from class org.eclipse.jface.viewers.Viewer

`addHelpListener, addSelectionChangedListener, fireHelpRequested, fireSelectionChanged, getData, handleHelpRequest, inputChanged, removeHelpListener, removeSelectionChangedListener, scrollDown, scrollUp, setData, setSelection`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.eclipse.jface.viewers.ISelectionProvider

`addSelectionChangedListener, removeSelectionChangedListener, setSelection`

## Constructor Details

### AbstractStructuredViewerWrapper

public AbstractStructuredViewerWrapper(org.eclipse.swt.widgets.Composite parent, EMFCompareConfiguration compareConfiguration)
Constructor.

Parameters:
  `parent` - the SWT parent control under which to create the viewer's SWT control.

## Method Details

### getCompareConfiguration

protected final EMFCompareConfiguration getCompareConfiguration()
Get the compare configuration object.

Returns:
  the compare configuration object.

### preHookCreateControlAndViewer

protected void preHookCreateControlAndViewer()

### createControlAndViewer

protected abstract AbstractStructuredViewerWrapper.ControlAndViewer<C,V> createControlAndViewer(org.eclipse.swt.widgets.Composite parent)
Should call `#setViewer(org.eclipse.jface.viewers.Viewer)`.

Parameters:
  `parent` - the SWT control under which to create the viewer.
Returns:
  a composite control that will contains all sub-control of this wrapper.

### getControl

public final C getControl()

Specified by:
  `getControl` in class `org.eclipse.jface.viewers.Viewer`
See Also:
  - `Viewer.getControl()`

### getViewer

protected final V getViewer()
Returns the `StructuredViewer` associated with this wrapper.

Returns:
  a StructuredViewer.

### handleDispose

protected void handleDispose(org.eclipse.swt.events.DisposeEvent event)

Overrides:
  `handleDispose` in class `org.eclipse.jface.viewers.StructuredViewer`

### setContentProvider

public final void setContentProvider(org.eclipse.jface.viewers.IContentProvider provider)

Overrides:
  `setContentProvider` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setContentProvider(org.eclipse.jface.viewers.IContentProvider)`

### setLabelProvider

public final void setLabelProvider(org.eclipse.jface.viewers.IBaseLabelProvider labelProvider)

Overrides:
  `setLabelProvider` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setLabelProvider(org.eclipse.jface.viewers.IBaseLabelProvider)`

### addDragSupport

public final void addDragSupport(int operations, org.eclipse.swt.dnd.Transfer[] transferTypes, org.eclipse.swt.dnd.DragSourceListener listener)

Overrides:
  `addDragSupport` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.addDragSupport(int, org.eclipse.swt.dnd.Transfer[], org.eclipse.swt.dnd.DragSourceListener)`

### addDropSupport

public final void addDropSupport(int operations, org.eclipse.swt.dnd.Transfer[] transferTypes, org.eclipse.swt.dnd.DropTargetListener listener)

Overrides:
  `addDropSupport` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.addDropSupport(int, org.eclipse.swt.dnd.Transfer[], org.eclipse.swt.dnd.DropTargetListener)`

### doFindInputItem

protected final org.eclipse.swt.widgets.Widget doFindInputItem(Object element)

Specified by:
  `doFindInputItem` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.doFindInputItem(java.lang.Object)`

### doFindItem

protected final org.eclipse.swt.widgets.Widget doFindItem(Object element)

Specified by:
  `doFindItem` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.doFindItem(java.lang.Object)`

### doUpdateItem

protected final void doUpdateItem(org.eclipse.swt.widgets.Widget item, Object element, boolean fullMap)

Specified by:
  `doUpdateItem` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.doUpdateItem(org.eclipse.swt.widgets.Widget, java.lang.Object, boolean)`

### getComparer

public final org.eclipse.jface.viewers.IElementComparer getComparer()

Overrides:
  `getComparer` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.getComparer()`

### addFilter

public final void addFilter(org.eclipse.jface.viewers.ViewerFilter filter)

Overrides:
  `addFilter` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.addFilter(org.eclipse.jface.viewers.ViewerFilter)`

### getFilters

public final org.eclipse.jface.viewers.ViewerFilter[] getFilters()

Overrides:
  `getFilters` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.getFilters()`

### removeFilter

public final void removeFilter(org.eclipse.jface.viewers.ViewerFilter filter)

Overrides:
  `removeFilter` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.removeFilter(org.eclipse.jface.viewers.ViewerFilter)`

### setFilters

public final void setFilters(org.eclipse.jface.viewers.ViewerFilter[] filters)

Overrides:
  `setFilters` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setFilters(org.eclipse.jface.viewers.ViewerFilter[])`

### resetFilters

public final void resetFilters()

Overrides:
  `resetFilters` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.resetFilters()`

### reveal

public final void reveal(Object element)

Specified by:
  `reveal` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.reveal(java.lang.Object)`

### getSelectionFromWidget

protected final List getSelectionFromWidget()

Specified by:
  `getSelectionFromWidget` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.getSelectionFromWidget()`

### getSorter

public final org.eclipse.jface.viewers.ViewerSorter getSorter()

Overrides:
  `getSorter` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.getSorter()`

### getComparator

public final org.eclipse.jface.viewers.ViewerComparator getComparator()

Overrides:
  `getComparator` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.getComparator()`

### setSelectionToWidget

protected final void setSelectionToWidget(List l, boolean reveal)

Specified by:
  `setSelectionToWidget` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setSelectionToWidget(java.util.List, boolean)`

### handleInvalidSelection

protected final void handleInvalidSelection(org.eclipse.jface.viewers.ISelection invalidSelection, org.eclipse.jface.viewers.ISelection newSelection)

Overrides:
  `handleInvalidSelection` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.handleInvalidSelection(org.eclipse.jface.viewers.ISelection, org.eclipse.jface.viewers.ISelection)`

### setSorter

public final void setSorter(org.eclipse.jface.viewers.ViewerSorter sorter)

Overrides:
  `setSorter` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setSorter(org.eclipse.jface.viewers.ViewerSorter)`

### setComparator

public final void setComparator(org.eclipse.jface.viewers.ViewerComparator comparator)

Overrides:
  `setComparator` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setComparator(org.eclipse.jface.viewers.ViewerComparator)`

### setUseHashlookup

public final void setUseHashlookup(boolean enable)

Overrides:
  `setUseHashlookup` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setUseHashlookup(boolean)`

### setComparer

public final void setComparer(org.eclipse.jface.viewers.IElementComparer comparer)

Overrides:
  `setComparer` in class `org.eclipse.jface.viewers.StructuredViewer`
See Also:
  - `StructuredViewer.setComparer(org.eclipse.jface.viewers.IElementComparer)`