CursorMatchers


class CursorMatchers


A collection of Hamcrest matchers that matches a data row in a Cursor.

AdapterViews that are backed by a Cursor are very common. This class contains Matcher s that can be used together with onData to match a data row in a Cursor. The Matchers can only operate on a single data row of the cursor and Espresso internally moves the Cursor to the correct adapter position.

Summary

Nested types

A Matcher that matches Cursors based on values in their columns.

Public functions

java-static CursorMatchers.CursorMatcher!
withRowBlob(columnIndex: Int, value: ByteArray!)

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

java-static CursorMatchers.CursorMatcher!
withRowBlob(columnIndex: Int, valueMatcher: Matcher<ByteArray!>!)

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

java-static CursorMatchers.CursorMatcher!
withRowBlob(columnName: String!, value: ByteArray!)

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

java-static CursorMatchers.CursorMatcher!
withRowBlob(columnName: String!, valueMatcher: Matcher<ByteArray!>!)

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

java-static CursorMatchers.CursorMatcher!
withRowBlob(
    columnPicker: Matcher<String!>!,
    valueMatcher: Matcher<ByteArray!>!
)

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

java-static CursorMatchers.CursorMatcher!
withRowDouble(columnIndex: Int, value: Double)

Returns a matcher that matches a Double value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowDouble(columnIndex: Int, valueMatcher: Matcher<Double!>!)

Returns a matcher that matches a Double value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowDouble(columnName: String!, value: Double)

Returns a matcher that matches a Double value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowDouble(columnName: String!, valueMatcher: Matcher<Double!>!)

Returns a matcher that matches a Double value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowDouble(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Double!>!
)

Returns a matcher that matches a Double value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowFloat(columnIndex: Int, value: Float)

Returns a matcher that matches a Float value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowFloat(columnIndex: Int, valueMatcher: Matcher<Float!>!)

Returns a matcher that matches a Float value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowFloat(columnName: String!, value: Float)

Returns a matcher that matches a Float value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowFloat(columnName: String!, valueMatcher: Matcher<Float!>!)

Returns a matcher that matches a Float value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowFloat(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Float!>!
)

Returns a matcher that matches a Float value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowInt(columnIndex: Int, value: Int)

Returns a matcher that matches a Integer value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowInt(columnIndex: Int, valueMatcher: Matcher<Int!>!)

Returns a matcher that matches a Integer value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowInt(columnName: String!, value: Int)

Returns a matcher that matches a Integer value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowInt(columnName: String!, valueMatcher: Matcher<Int!>!)

Returns a matcher that matches a Integer value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowInt(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Int!>!
)

Returns a matcher that matches a Integer value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowLong(columnIndex: Int, value: Long)

Returns a matcher that matches a Long value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowLong(columnIndex: Int, valueMatcher: Matcher<Long!>!)

Returns a matcher that matches a Long value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowLong(columnName: String!, value: Long)

Returns a matcher that matches a Long value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowLong(columnName: String!, valueMatcher: Matcher<Long!>!)

Returns a matcher that matches a Long value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowLong(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Long!>!
)

Returns a matcher that matches a Long value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowShort(columnIndex: Int, value: Short)

Returns a matcher that matches a Short value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowShort(columnIndex: Int, valueMatcher: Matcher<Short!>!)

Returns a matcher that matches a Short value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowShort(columnName: String!, value: Short)

Returns a matcher that matches a Short value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowShort(columnName: String!, valueMatcher: Matcher<Short!>!)

Returns a matcher that matches a Short value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowShort(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Short!>!
)

Returns a matcher that matches a Short value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowString(columnIndex: Int, value: String!)

Returns a matcher that matches a String value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowString(columnIndex: Int, valueMatcher: Matcher<String!>!)

Returns a matcher that matches a String value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowString(columnName: String!, value: String!)

Returns a matcher that matches a String value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowString(columnName: String!, valueMatcher: Matcher<String!>!)

Returns a matcher that matches a String value at a given column index in a s data row.

java-static CursorMatchers.CursorMatcher!
withRowString(
    columnPicker: Matcher<String!>!,
    valueMatcher: Matcher<String!>!
)

Returns a matcher that matches a String value at a given column index in a s data row.

Public functions

withRowBlob

java-static fun withRowBlob(columnIndex: Int, value: ByteArray!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

Parameters
columnIndex: Int

int column index

value: ByteArray!

byte[] to match

withRowBlob

java-static fun withRowBlob(columnIndex: Int, valueMatcher: Matcher<ByteArray!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<ByteArray!>!

a Matcher that matches a byte[]

withRowBlob

java-static fun withRowBlob(columnName: String!, value: ByteArray!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

Parameters
columnName: String!

as a String

value: ByteArray!

byte[] to match

withRowBlob

java-static fun withRowBlob(columnName: String!, valueMatcher: Matcher<ByteArray!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<ByteArray!>!

a Matcher that matches a byte[]

withRowBlob

java-static fun withRowBlob(
    columnPicker: Matcher<String!>!,
    valueMatcher: Matcher<ByteArray!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a byte[] at a given column index in a Cursors data row.

Parameters
columnPicker: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<ByteArray!>!

a Matcher that matches a byte[]

withRowDouble

java-static fun withRowDouble(columnIndex: Int, value: Double): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Double value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: Double

a double value to match

withRowDouble

java-static fun withRowDouble(columnIndex: Int, valueMatcher: Matcher<Double!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Double value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<Double!>!

a Matcher that matches a Double value

withRowDouble

java-static fun withRowDouble(columnName: String!, value: Double): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Double value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: Double

a double value to match

withRowDouble

java-static fun withRowDouble(columnName: String!, valueMatcher: Matcher<Double!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Double value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<Double!>!

a Matcher that matches a Double value

withRowDouble

java-static fun withRowDouble(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Double!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Double value at a given column index in a s data row.

Parameters
columnNameMatcher: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<Double!>!

a Matcher that matches a Double value

withRowFloat

java-static fun withRowFloat(columnIndex: Int, value: Float): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Float value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: Float

a float value to match

withRowFloat

java-static fun withRowFloat(columnIndex: Int, valueMatcher: Matcher<Float!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Float value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<Float!>!

a Matcher that matches a Float value

withRowFloat

java-static fun withRowFloat(columnName: String!, value: Float): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Float value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: Float

a float value to match

withRowFloat

java-static fun withRowFloat(columnName: String!, valueMatcher: Matcher<Float!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Float value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<Float!>!

a Matcher that matches a Float value

withRowFloat

java-static fun withRowFloat(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Float!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Float value at a given column index in a s data row.

Parameters
columnNameMatcher: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<Float!>!

a Matcher that matches a Float value

withRowInt

java-static fun withRowInt(columnIndex: Int, value: Int): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Integer value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: Int

a int value to match

withRowInt

java-static fun withRowInt(columnIndex: Int, valueMatcher: Matcher<Int!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Integer value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<Int!>!

a Matcher that matches a Integer value

withRowInt

java-static fun withRowInt(columnName: String!, value: Int): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Integer value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: Int

a int value to match

withRowInt

java-static fun withRowInt(columnName: String!, valueMatcher: Matcher<Int!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Integer value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<Int!>!

a Matcher that matches a Integer value

withRowInt

java-static fun withRowInt(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Int!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Integer value at a given column index in a s data row.

Parameters
columnNameMatcher: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<Int!>!

a Matcher that matches a Integer value

withRowLong

java-static fun withRowLong(columnIndex: Int, value: Long): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Long value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: Long

a long value to match

withRowLong

java-static fun withRowLong(columnIndex: Int, valueMatcher: Matcher<Long!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Long value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<Long!>!

a Matcher that matches a Long value

withRowLong

java-static fun withRowLong(columnName: String!, value: Long): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Long value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: Long

a long value to match

withRowLong

java-static fun withRowLong(columnName: String!, valueMatcher: Matcher<Long!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Long value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<Long!>!

a Matcher that matches a Long value

withRowLong

java-static fun withRowLong(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Long!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Long value at a given column index in a s data row.

Parameters
columnNameMatcher: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<Long!>!

a Matcher that matches a Long value

withRowShort

java-static fun withRowShort(columnIndex: Int, value: Short): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Short value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: Short

a short value to match

withRowShort

java-static fun withRowShort(columnIndex: Int, valueMatcher: Matcher<Short!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Short value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<Short!>!

a Matcher that matches a Short value

withRowShort

java-static fun withRowShort(columnName: String!, value: Short): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Short value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: Short

a short value to match

withRowShort

java-static fun withRowShort(columnName: String!, valueMatcher: Matcher<Short!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Short value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<Short!>!

a Matcher that matches a Short value

withRowShort

java-static fun withRowShort(
    columnNameMatcher: Matcher<String!>!,
    valueMatcher: Matcher<Short!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a Short value at a given column index in a s data row.

Parameters
columnNameMatcher: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<Short!>!

a Matcher that matches a Short value

withRowString

java-static fun withRowString(columnIndex: Int, value: String!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a String value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

value: String!

a String value to match

withRowString

java-static fun withRowString(columnIndex: Int, valueMatcher: Matcher<String!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a String value at a given column index in a s data row.

Parameters
columnIndex: Int

int column index

valueMatcher: Matcher<String!>!

a Matcher that matches a String value

withRowString

java-static fun withRowString(columnName: String!, value: String!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a String value at a given column index in a s data row.

Parameters
columnName: String!

as a String

value: String!

a String value to match

withRowString

java-static fun withRowString(columnName: String!, valueMatcher: Matcher<String!>!): CursorMatchers.CursorMatcher!

Returns a matcher that matches a String value at a given column index in a s data row.

Parameters
columnName: String!

as a String

valueMatcher: Matcher<String!>!

a Matcher that matches a String value

withRowString

java-static fun withRowString(
    columnPicker: Matcher<String!>!,
    valueMatcher: Matcher<String!>!
): CursorMatchers.CursorMatcher!

Returns a matcher that matches a String value at a given column index in a s data row.

Parameters
columnPicker: Matcher<String!>!

as a Matcher of String

valueMatcher: Matcher<String!>!

a Matcher that matches a String value