Class RadioGroupViewer
java.lang.Object
org.eclipse.jface.viewers.Viewer
org.eclipse.jface.viewers.ContentViewer
org.eclipse.jface.viewers.StructuredViewer
org.eclipse.jface.viewers.AbstractListViewer
org.eclipse.nebula.jface.viewer.radiogroup.RadioGroupViewer
- All Implemented Interfaces:
org.eclipse.jface.viewers.IInputProvider
,org.eclipse.jface.viewers.IInputSelectionProvider
,org.eclipse.jface.viewers.IPostSelectionProvider
,org.eclipse.jface.viewers.ISelectionProvider
public class RadioGroupViewer
extends org.eclipse.jface.viewers.AbstractListViewer
A concrete viewer based on a Nebula
RadioGroup
control.
PROVISIONAL: The superclass hierarchy of this viewer is provisional and expected to change. Specifically we plan to change this class to extend a new ItemViewer class in the near future. Therefore clients should avoid using API declared only in AbstractListViewer (however APIs declared in StructuredViewer and its superclasses are safe to use). Unsafe methods are tagged "noreference" in the javadoc.
- Since:
- 3.5
-
Nested Class Summary
-
Field Summary
-
Constructor Summary
Constructors Constructor Description RadioGroupViewer(RadioGroup group)
Creates a radio group viewer on the givenRadioGroup
control.RadioGroupViewer(org.eclipse.swt.widgets.Composite parent)
Creates a radio group viewer on a newly-createdRadioGroup
control under the given parent.RadioGroupViewer(org.eclipse.swt.widgets.Composite parent, int style)
Creates a radio group viewer on a newly-createdRadioGroup
control under the given parent. -
Method Summary
Modifier and Type Method Description void
add(java.lang.Object element)
void
add(java.lang.Object[] elements)
org.eclipse.swt.widgets.Control
getControl()
java.lang.Object
getElementAt(int index)
RadioGroup
getRadioGroup()
Returns this viewer'sRadioGroup
control.protected int
indexForElement(java.lang.Object element)
void
insert(java.lang.Object element, int position)
protected void
listAdd(java.lang.String string, int index)
protected void
listDeselectAll()
protected int
listGetItemCount()
protected int[]
listGetSelectionIndices()
protected int
listGetTopIndex()
protected void
listRemove(int index)
protected void
listRemoveAll()
protected void
listSetItem(int index, java.lang.String string)
protected void
listSetItems(java.lang.String[] labels)
protected void
listSetSelection(int[] ixs)
protected void
listSetTopIndex(int index)
protected void
listShowSelection()
void
remove(java.lang.Object element)
void
remove(java.lang.Object[] elements)
void
reveal(java.lang.Object element)
Methods inherited from class org.eclipse.jface.viewers.AbstractListViewer
doFindInputItem, doFindItem, doUpdateItem, getLabelProvider, getSelectionFromWidget, inputChanged, internalRefresh, setLabelProvider, setSelectionToWidget
Methods inherited from class org.eclipse.jface.viewers.StructuredViewer
addDoubleClickListener, addDragSupport, addDropSupport, addFilter, addOpenListener, addPostSelectionChangedListener, assertContentProviderType, assertElementsNotNull, associate, buildLabel, disassociate, equals, filter, findItem, findItems, fireDoubleClick, fireOpen, firePostSelectionChanged, getColorAndFontCollector, getComparator, getComparer, getFilteredChildren, getFilters, getItem, getRawChildren, getRoot, getSelection, getSortedChildren, getSorter, getStructuredSelection, handleDispose, handleDoubleSelect, handleInvalidSelection, handleLabelProviderChanged, handleOpen, handlePostSelect, handleSelect, hasFilters, hookControl, internalRefresh, internalUpdate, mapElement, needsRefilter, preservingSelection, refresh, refresh, refresh, refresh, refreshItem, removeDoubleClickListener, removeFilter, removeOpenListener, removePostSelectionChangedListener, resetFilters, setComparator, setComparer, setContentProvider, setFilters, setInput, setSelection, setSelectionToWidget, setSorter, setUseHashlookup, testFindItem, testFindItems, unmapAllElements, unmapElement, unmapElement, update, update, updateItem, updateSelection, usingElementMap
Methods inherited from class org.eclipse.jface.viewers.ContentViewer
getContentProvider, getInput, labelProviderChanged
Methods inherited from class org.eclipse.jface.viewers.Viewer
addHelpListener, addSelectionChangedListener, fireHelpRequested, fireSelectionChanged, getData, handleHelpRequest, removeHelpListener, removeSelectionChangedListener, scrollDown, scrollUp, setData, setSelection
-
Constructor Details
-
RadioGroupViewer
public RadioGroupViewer(org.eclipse.swt.widgets.Composite parent)Creates a radio group viewer on a newly-createdRadioGroup
control under the given parent. The viewer has no input, no content provider, a default label provider, no sorter, and no filters.- Parameters:
parent
- the parent control
-
RadioGroupViewer
public RadioGroupViewer(org.eclipse.swt.widgets.Composite parent, int style)Creates a radio group viewer on a newly-createdRadioGroup
control under the given parent. The radio group control is created using the given style bits. The viewer has no input, no content provider, a default label provider, no sorter, and no filters.- Parameters:
parent
- the parent controlstyle
- SWT style bits
-
RadioGroupViewer
Creates a radio group viewer on the givenRadioGroup
control. The viewer has no input, no content provider, a default label provider, no sorter, and no filters.- Parameters:
group
- the RadioGroup control
-
-
Method Details
-
add
public void add(java.lang.Object element)- Overrides:
add
in classorg.eclipse.jface.viewers.AbstractListViewer
-
add
public void add(java.lang.Object[] elements)- Overrides:
add
in classorg.eclipse.jface.viewers.AbstractListViewer
-
getControl
public org.eclipse.swt.widgets.Control getControl()- Specified by:
getControl
in classorg.eclipse.jface.viewers.Viewer
- See Also:
Viewer.getControl()
-
getElementAt
public java.lang.Object getElementAt(int index)- Overrides:
getElementAt
in classorg.eclipse.jface.viewers.AbstractListViewer
-
getRadioGroup
Returns this viewer'sRadioGroup
control.- Returns:
- the RadioGroup control
-
indexForElement
protected int indexForElement(java.lang.Object element)- Overrides:
indexForElement
in classorg.eclipse.jface.viewers.AbstractListViewer
-
insert
public void insert(java.lang.Object element, int position)- Overrides:
insert
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listAdd
protected void listAdd(java.lang.String string, int index)- Specified by:
listAdd
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listDeselectAll
protected void listDeselectAll()- Specified by:
listDeselectAll
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listGetItemCount
protected int listGetItemCount()- Specified by:
listGetItemCount
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listGetSelectionIndices
protected int[] listGetSelectionIndices()- Specified by:
listGetSelectionIndices
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listGetTopIndex
protected int listGetTopIndex()- Overrides:
listGetTopIndex
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listRemove
protected void listRemove(int index)- Specified by:
listRemove
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listRemoveAll
protected void listRemoveAll()- Specified by:
listRemoveAll
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listSetItem
protected void listSetItem(int index, java.lang.String string)- Specified by:
listSetItem
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listSetItems
protected void listSetItems(java.lang.String[] labels)- Specified by:
listSetItems
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listSetSelection
protected void listSetSelection(int[] ixs)- Specified by:
listSetSelection
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listSetTopIndex
protected void listSetTopIndex(int index)- Overrides:
listSetTopIndex
in classorg.eclipse.jface.viewers.AbstractListViewer
-
listShowSelection
protected void listShowSelection()- Specified by:
listShowSelection
in classorg.eclipse.jface.viewers.AbstractListViewer
-
remove
public void remove(java.lang.Object element)- Overrides:
remove
in classorg.eclipse.jface.viewers.AbstractListViewer
-
remove
public void remove(java.lang.Object[] elements)- Overrides:
remove
in classorg.eclipse.jface.viewers.AbstractListViewer
-
reveal
public void reveal(java.lang.Object element)- Specified by:
reveal
in classorg.eclipse.jface.viewers.StructuredViewer
-