Uses of Interface
org.mockito.ArgumentMatcher
Packages that use ArgumentMatcher
Package
Description
Mockito is a mock library for java - see
Mockito class for usage.Invocation machinery and related classes.
Argument matchers for verification and stubbing.
Argument matchers that use Apache Commons Lang reflection-equality.
Mocking progress stateful classes.
Deals with nicely printing verification errors.
Deals with matching arguments.
Public API related to mock method invocations.
-
Uses of ArgumentMatcher in org.mockito
Methods in org.mockito with parameters of type ArgumentMatcherModifier and TypeMethodDescriptionstatic <T> TArgumentMatchers.argThat(ArgumentMatcher<T> matcher) Allows creating custom argument matchers.static booleanArgumentMatchers.booleanThat(ArgumentMatcher<Boolean> matcher) Allows creating custombooleanargument matchers.static byteArgumentMatchers.byteThat(ArgumentMatcher<Byte> matcher) Allows creating custombyteargument matchers.static charArgumentMatchers.charThat(ArgumentMatcher<Character> matcher) Allows creating customcharargument matchers.static doubleArgumentMatchers.doubleThat(ArgumentMatcher<Double> matcher) Allows creating customdoubleargument matchers.static floatArgumentMatchers.floatThat(ArgumentMatcher<Float> matcher) Allows creating customfloatargument matchers.static intArgumentMatchers.intThat(ArgumentMatcher<Integer> matcher) Allows creating customintargument matchers.static longArgumentMatchers.longThat(ArgumentMatcher<Long> matcher) Allows creating customlongargument matchers.private static voidAdditionalMatchers.reportMatcher(ArgumentMatcher<?> matcher) private static voidArgumentMatchers.reportMatcher(ArgumentMatcher<?> matcher) static shortArgumentMatchers.shortThat(ArgumentMatcher<Short> matcher) Allows creating customshortargument matchers. -
Uses of ArgumentMatcher in org.mockito.internal.hamcrest
Classes in org.mockito.internal.hamcrest that implement ArgumentMatcher -
Uses of ArgumentMatcher in org.mockito.internal.invocation
Fields in org.mockito.internal.invocation with type parameters of type ArgumentMatcherModifier and TypeFieldDescriptionprivate final List<ArgumentMatcher<?>> InvocationMatcher.matchersprivate final List<? extends ArgumentMatcher<?>> MatcherApplicationStrategy.matchersMethods in org.mockito.internal.invocation that return types with arguments of type ArgumentMatcherModifier and TypeMethodDescriptionstatic List<ArgumentMatcher> ArgumentsProcessor.argumentsToMatchers(Object[] arguments) InterceptedInvocation.getArgumentsAsMatchers()InvocationMatcher.getMatchers()Methods in org.mockito.internal.invocation with parameters of type ArgumentMatcherModifier and TypeMethodDescriptionbooleanArgumentMatcherAction.apply(ArgumentMatcher<?> matcher, Object argument) Implementations must apply the given matcher to the argument and returntrueif the operation was successful orfalseif not.booleanTypeSafeMatching.apply(ArgumentMatcher matcher, Object argument) private static Class<?> TypeSafeMatching.getArgumentType(ArgumentMatcher<?> matcher) private static Class<?> TypeSafeMatching.getArgumentTypeUncached(ArgumentMatcher<?> argumentMatcher) Returns the type ofArgumentMatcher.matches(Object)of the givenArgumentMatcherimplementation.private static booleanTypeSafeMatching.isCompatible(ArgumentMatcher<?> argumentMatcher, Object argument) Returnstrueif the given argument can be passed to the givenargumentMatcherwithout causing aClassCastException.Method parameters in org.mockito.internal.invocation with type arguments of type ArgumentMatcherModifier and TypeMethodDescriptionprivate booleanMatcherApplicationStrategy.argsMatch(Object[] arguments, List<? extends ArgumentMatcher<?>> matchers, ArgumentMatcherAction action) static MatcherApplicationStrategyMatcherApplicationStrategy.getMatcherApplicationStrategyFor(Invocation invocation, List<? extends ArgumentMatcher<?>> matchers) Returns theMatcherApplicationStrategythat must be used to capture the arguments of the given invocation using the given matchers.Constructor parameters in org.mockito.internal.invocation with type arguments of type ArgumentMatcherModifierConstructorDescriptionInvocationMatcher(Invocation invocation, List<ArgumentMatcher> matchers) privateMatcherApplicationStrategy(Invocation invocation, List<? extends ArgumentMatcher<?>> matchers) -
Uses of ArgumentMatcher in org.mockito.internal.matchers
Classes in org.mockito.internal.matchers that implement ArgumentMatcherModifier and TypeClassDescriptionclassclassclassclassclassCompareEqual<T extends Comparable<T>>classCompareTo<T extends Comparable<T>>classclassclassclassclassclassGreaterOrEqual<T extends Comparable<T>>classGreaterThan<T extends Comparable<T>>classclassLessOrEqual<T extends Comparable<T>>classLessThan<T extends Comparable<T>>classclassclassNotNull<T>classNull<T>classclassclassFields in org.mockito.internal.matchers declared as ArgumentMatcherModifier and TypeFieldDescriptionprivate final ArgumentMatcherAnd.m1private final ArgumentMatcherOr.m1private final ArgumentMatcherAnd.m2private final ArgumentMatcherOr.m2private final ArgumentMatcher<?> LocalizedMatcher.matcherprivate final ArgumentMatcherNot.matcherMethods in org.mockito.internal.matchers that return ArgumentMatcherConstructors in org.mockito.internal.matchers with parameters of type ArgumentMatcherModifierConstructorDescriptionAnd(ArgumentMatcher<?> m1, ArgumentMatcher<?> m2) LocalizedMatcher(ArgumentMatcher<?> matcher) Not(ArgumentMatcher<?> matcher) Or(ArgumentMatcher<?> m1, ArgumentMatcher<?> m2) -
Uses of ArgumentMatcher in org.mockito.internal.matchers.apachecommons
Classes in org.mockito.internal.matchers.apachecommons that implement ArgumentMatcher -
Uses of ArgumentMatcher in org.mockito.internal.matchers.text
Methods in org.mockito.internal.matchers.text with parameters of type ArgumentMatcherModifier and TypeMethodDescription(package private) static StringMatcherToString.toString(ArgumentMatcher<?> matcher) Attempts to provide more descriptive toString() for given matcher.Method parameters in org.mockito.internal.matchers.text with type arguments of type ArgumentMatcherModifier and TypeMethodDescriptionprivate Iterator<FormattedText> MatchersPrinter.applyPrintSettings(List<ArgumentMatcher> matchers, PrintSettings printSettings) MatchersPrinter.getArgumentsBlock(List<ArgumentMatcher> matchers, PrintSettings printSettings) MatchersPrinter.getArgumentsLine(List<ArgumentMatcher> matchers, PrintSettings printSettings) -
Uses of ArgumentMatcher in org.mockito.internal.progress
Methods in org.mockito.internal.progress that return ArgumentMatcherModifier and TypeMethodDescriptionprivate ArgumentMatcher<?> ArgumentMatcherStorageImpl.popMatcher()Methods in org.mockito.internal.progress with parameters of type ArgumentMatcherModifier and TypeMethodDescriptionvoidArgumentMatcherStorage.reportMatcher(ArgumentMatcher<?> matcher) voidArgumentMatcherStorageImpl.reportMatcher(ArgumentMatcher<?> matcher) -
Uses of ArgumentMatcher in org.mockito.internal.reporting
Method parameters in org.mockito.internal.reporting with type arguments of type ArgumentMatcherModifier and TypeMethodDescriptionPrintSettings.print(List<ArgumentMatcher> matchers, Invocation invocation) -
Uses of ArgumentMatcher in org.mockito.internal.verification.argumentmatching
Methods in org.mockito.internal.verification.argumentmatching with parameters of type ArgumentMatcherModifier and TypeMethodDescriptionprivate static booleanArgumentMatchingTool.safelyMatches(ArgumentMatcher m, Object arg) private static booleanArgumentMatchingTool.toStringEquals(ArgumentMatcher m, Object arg) Method parameters in org.mockito.internal.verification.argumentmatching with type arguments of type ArgumentMatcherModifier and TypeMethodDescriptionArgumentMatchingTool.getNotMatchingArgsIndexes(List<ArgumentMatcher> matchers, Object[] arguments) Returns indexes of arguments not matching the provided matchers.ArgumentMatchingTool.getNotMatchingArgsWithSameName(List<ArgumentMatcher> matchers, Object[] arguments) Suspiciously not matching arguments are those that don't match, and the classes have same simple name.static Integer[]ArgumentMatchingTool.getSuspiciouslyNotMatchingArgsIndexes(List<ArgumentMatcher> matchers, Object[] arguments) Suspiciously not matching arguments are those that don't match, the toString() representation is the same but types are different. -
Uses of ArgumentMatcher in org.mockito.invocation
Methods in org.mockito.invocation that return types with arguments of type ArgumentMatcherModifier and TypeMethodDescriptionInvocation.getArgumentsAsMatchers()Wraps each argument usingArgumentMatchers.eq(Object)orAdditionalMatchers.aryEq(Object[])Used internally for the purposes of human-readable invocation printing.MatchableInvocation.getMatchers()The argument matchers of this invocation.