Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.swtbot.swt.finder.matchers
Class WithItem<T extends Item>

    java.lang.Object
      org.hamcrest.BaseMatcher<T>
          org.eclipse.swtbot.swt.finder.matchers.AbstractMatcher<T>
              org.eclipse.swtbot.swt.finder.matchers.WithItem<T>

All Implemented Interfaces:
  Matcher<T>, SelfDescribing

    public class WithItem<T extends Item>

extends AbstractMatcher<T>

Version:
  $Id$
Author:
  Ketan Patel (Bug 259860)

Field Summary

Fields inherited from class org.eclipse.swtbot.swt.finder.matchers.AbstractMatcher
`log`

Method Summary
`void` | `describeTo(Description description)`
`protected boolean` | `doMatch(Object obj)` Subclasses must override, this is the actual method that does the matching
`T` | `get(int index)`
`ArrayList<T>` | `getAllMatches()`
`static
`<T extends Item> WithItem<T>`
` | `withItem(Matcher<?> matcher)` Returns a matcher that matches objects containing an item that matches the matcher.

Methods inherited from class org.eclipse.swtbot.swt.finder.matchers.AbstractMatcher
`matches`

Methods inherited from class org.hamcrest.BaseMatcher
`_dont_implement_Matcher___instead_extend_BaseMatcher_, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Method Detail

### describeTo

    public void describeTo(Description description)

### doMatch

    protected boolean doMatch(Object obj)

  Description copied from class: `AbstractMatcher`
  Subclasses must override, this is the actual method that does the matching

  Specified by:
    `doMatch` in class `AbstractMatcher<T extends Item>`
  Parameters:
    `obj` - the item to match.
  Returns:
    `true` if the item matches, `false` otherwise.

### getAllMatches

    public ArrayList<T> getAllMatches()

### get

    public T get(int index)

### withItem

    public static <T extends Item> WithItem<T> withItem(Matcher<?> matcher)

  Returns a matcher that matches objects containing an item that matches the matcher.

  Note: This invokes getItems method on the object and expects to see an array as a return value.

  Parameters:
    `matcher` - the matcher.
  Returns:
    a matcher.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD