org.eclipse.swtbot.swt.finder.utils.internal
Class WidgetIndexFinder

java.lang.Object
  extended by org.eclipse.swtbot.swt.finder.utils.internal.WidgetIndexFinder
All Implemented Interfaces:
IntResult, Result<Integer>

public final class WidgetIndexFinder
extends Object
implements IntResult

This is used to find the sibling widget and its index.

NOTE: This finds all the siblings and finds the index of the widget among the siblings. This does not use SWTUtils to find siblings for performance reasons

Author:
Ketan Padegaonkar <KetanPadegaonkar [at] gmail [dot] com>
See Also:
PreviousWidgetFinder, NextWidgetFinder

Constructor Summary
WidgetIndexFinder(Widget w)
          Constructs the widget index finder for the given widget.
 
Method Summary
 Integer run()
          Runs the finder to locate the index of the sibling.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WidgetIndexFinder

public WidgetIndexFinder(Widget w)
Constructs the widget index finder for the given widget.

Parameters:
w - the widget.
Method Detail

run

public Integer run()
Runs the finder to locate the index of the sibling.

Specified by:
run in interface Result<Integer>
Returns:
The index value.
See Also:
Result.run()