ImmutableSearchProperty implements SearchProperty { @Override public PropertySearchFilter like(final String value) { checkStringValue(value); return ImmutablePropertyFilter.of(SearchFilter.Type.LIKE, propertyPath, JsonFactory.newValue(value)); } private  ImmutableSearchProperty(final JsonPointer thePropertyPath); static ImmutableSearchProperty of(final JsonPointer propertyPath); @Override PropertySearchFilter exists(); @Override PropertySearchFilter eq(final boolean value); @Override PropertySearchFilter eq(final int value); @Override PropertySearchFilter eq(final long value); @Override PropertySearchFilter eq(final double value); @Override PropertySearchFilter eq(@Nullable final String value); @Override PropertySearchFilter ne(final boolean value); @Override PropertySearchFilter ne(final int value); @Override PropertySearchFilter ne(final long value); @Override PropertySearchFilter ne(final double value); @Override PropertySearchFilter ne(@Nullable final String value); @Override PropertySearchFilter ge(final boolean value); @Override PropertySearchFilter ge(final int value); @Override PropertySearchFilter ge(final long value); @Override PropertySearchFilter ge(final double value); @Override PropertySearchFilter ge(final String value); @Override PropertySearchFilter gt(final boolean value); @Override PropertySearchFilter gt(final int value); @Override PropertySearchFilter gt(final long value); @Override PropertySearchFilter gt(final double value); @Override PropertySearchFilter gt(final String value); @Override PropertySearchFilter le(final boolean value); @Override PropertySearchFilter le(final int value); @Override PropertySearchFilter le(final long value); @Override PropertySearchFilter le(final double value); @Override PropertySearchFilter le(final String value); @Override PropertySearchFilter lt(final boolean value); @Override PropertySearchFilter lt(final int value); @Override PropertySearchFilter lt(final long value); @Override PropertySearchFilter lt(final double value); @Override PropertySearchFilter lt(final String value); @Override PropertySearchFilter like(final String value); @Override PropertySearchFilter in(final boolean value, final Boolean... furtherValues); @Override PropertySearchFilter in(final int value, final Integer... furtherValues); @Override PropertySearchFilter in(final long value, final Long... furtherValues); @Override PropertySearchFilter in(final double value, final Double... furtherValues); @Override PropertySearchFilter in(final String value, final String... furtherValues); @Override PropertySearchFilter in(final Collection<JsonValue> values); @Override JsonPointer getPath(); @Override boolean equals(final Object o); @Override int hashCode(); @Override String toString();  }
@Test(expected = NullPointerException.class) public void tryToCallLikeWithNull() { underTest.like(null); }
@Test public void likeReturnsExpected() { assertThat(underTest.like(BOSCH)) .hasType(SearchFilter.Type.LIKE) .hasOnlyValue(BOSCH) .hasStringRepresentation("like(" + PROPERTY_PATH + ",\"" + BOSCH + "\")"); }