com.atlassian.jira.matchers
Class IterableMatchers

java.lang.Object
  extended by com.atlassian.jira.matchers.IterableMatchers

public final class IterableMatchers
extends Object

Some moar iterable matchers.

Since:
5.1

Method Summary
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsAt(E item, int at)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsAt(org.hamcrest.Matcher<E> itemMatcher, int at)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsFirst(E item)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsFirst(org.hamcrest.Matcher<E> itemMatcher)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsLast(E item)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
containsLast(org.hamcrest.Matcher<E> itemMatcher)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
emptyIterable(Class<E> elementType)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasItems(Class<E> itemType, E... items)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasItemsThat(Class<E> itemType, org.hamcrest.Matcher<E>... items)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasItemThat(org.hamcrest.Matcher<E> itemMatcher)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasNoItemThat(org.hamcrest.Matcher<E> itemMatcher)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasSizeOfAtLeast(int expectedMinimumSize)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
hasSizeOfAtLeast(int expectedMinimumSize, Class<E> elementType)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
isSingleton(Class<E> type, E singleElement)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
isSingleton(E expectedElement)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
isSingleton(org.hamcrest.Matcher<E> singleElementMatcher)
           
static
<E> org.hamcrest.Matcher<Iterable<E>>
iterableWithSize(int expected, Class<E> elementType)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

emptyIterable

public static <E> org.hamcrest.Matcher<Iterable<E>> emptyIterable(Class<E> elementType)

iterableWithSize

public static <E> org.hamcrest.Matcher<Iterable<E>> iterableWithSize(int expected,
                                                                     Class<E> elementType)

hasSizeOfAtLeast

public static <E> org.hamcrest.Matcher<Iterable<E>> hasSizeOfAtLeast(int expectedMinimumSize,
                                                                     Class<E> elementType)

hasSizeOfAtLeast

public static <E> org.hamcrest.Matcher<Iterable<E>> hasSizeOfAtLeast(int expectedMinimumSize)

isSingleton

public static <E> org.hamcrest.Matcher<Iterable<E>> isSingleton(Class<E> type,
                                                                E singleElement)

isSingleton

public static <E> org.hamcrest.Matcher<Iterable<E>> isSingleton(E expectedElement)

isSingleton

public static <E> org.hamcrest.Matcher<Iterable<E>> isSingleton(org.hamcrest.Matcher<E> singleElementMatcher)

hasItems

public static <E> org.hamcrest.Matcher<Iterable<E>> hasItems(Class<E> itemType,
                                                             E... items)

hasItemsThat

public static <E> org.hamcrest.Matcher<Iterable<E>> hasItemsThat(Class<E> itemType,
                                                                 org.hamcrest.Matcher<E>... items)

hasItemThat

public static <E> org.hamcrest.Matcher<Iterable<E>> hasItemThat(org.hamcrest.Matcher<E> itemMatcher)

hasNoItemThat

public static <E> org.hamcrest.Matcher<Iterable<E>> hasNoItemThat(org.hamcrest.Matcher<E> itemMatcher)

containsAt

public static <E> org.hamcrest.Matcher<Iterable<E>> containsAt(E item,
                                                               int at)

containsFirst

public static <E> org.hamcrest.Matcher<Iterable<E>> containsFirst(E item)

containsFirst

public static <E> org.hamcrest.Matcher<Iterable<E>> containsFirst(org.hamcrest.Matcher<E> itemMatcher)

containsLast

public static <E> org.hamcrest.Matcher<Iterable<E>> containsLast(E item)

containsLast

public static <E> org.hamcrest.Matcher<Iterable<E>> containsLast(org.hamcrest.Matcher<E> itemMatcher)

containsAt

public static <E> org.hamcrest.Matcher<Iterable<E>> containsAt(org.hamcrest.Matcher<E> itemMatcher,
                                                               int at)


Copyright © 2002-2014 Atlassian. All Rights Reserved.