/** * Create a new CONTAINS specification for a Collection Property. * * @param <T> Collection property type * @param collectionProperty a Collection Property * @param value the value * * @return a new CONTAINS specification for a Collection Property. */ public static <T> ContainsPredicate<T> contains( Property<? extends Collection<T>> collectionProperty, T value ) { Objects.requireNonNull( value, "Value" ); return new ContainsPredicate<>( property( collectionProperty ), value ); }
/** * Create a new CONTAINS specification for a Collection Property using named Variables. * * @param <T> Collection property type * @param collectionProperty a Collection Property * @param variable named Variable * * @return a new CONTAINS specification for a Collection Property using named Variables. */ @SuppressWarnings( {"raw", "unchecked"} ) public static <T> ContainsPredicate<T> contains( Property<? extends Collection<T>> collectionProperty, Variable variable ) { Objects.requireNonNull( variable, "Variable" ); return new ContainsPredicate( property( collectionProperty ), variable ); }
/** * Create a new CONTAINS specification for a Collection Property. * * @param <T> Collection property type * @param collectionProperty a Collection Property * @param value the value * * @return a new CONTAINS specification for a Collection Property. */ public static <T> ContainsPredicate<T> contains( Property<? extends Collection<T>> collectionProperty, T value ) { Objects.requireNonNull( value, "Value" ); return new ContainsPredicate<>( property( collectionProperty ), value ); }
/** * Create a new CONTAINS specification for a Collection Property using named Variables. * * @param <T> Collection property type * @param collectionProperty a Collection Property * @param variable named Variable * * @return a new CONTAINS specification for a Collection Property using named Variables. */ @SuppressWarnings( {"raw", "unchecked"} ) public static <T> ContainsPredicate<T> contains( Property<? extends Collection<T>> collectionProperty, Variable variable ) { Objects.requireNonNull( variable, "Variable" ); return new ContainsPredicate( property( collectionProperty ), variable ); }