/** * Creates an hamcrest matcher that is evalued to true if the value of the given argument satisfies * the condition defined by the passed matcher. * @param argument The argument defined using the {@link ch.lambdaj.Lambda#on(Class)} method that has to be matched * @param matcher The matcher against which the value of the given argument has to be compared * @return The hamcrest matcher that is evalued to true if the value of the passed argument matches the given matcher */ @Factory public static <T, A> HasArgumentWithValue<T, A> havingValue(A argument, Matcher<?> matcher) { return new HasArgumentWithValue<T, A>(actualArgument(argument), matcher); }