Package org.springframework.data.domain
Class ExampleMatcher.GenericPropertyMatcher
java.lang.Object
org.springframework.data.domain.ExampleMatcher.GenericPropertyMatcher
- Enclosing interface:
- ExampleMatcher
A generic property matcher that specifies
string matching
and case sensitivity.- Author:
- Mark Paluch
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
Sets ignores case to false.contains()
Sets string matcher toExampleMatcher.StringMatcher.CONTAINING
.endsWith()
Sets string matcher toExampleMatcher.StringMatcher.ENDING
.boolean
exact()
Sets string matcher toExampleMatcher.StringMatcher.EXACT
.int
hashCode()
Sets ignores case to true.ignoreCase
(boolean ignoreCase) Sets ignores case toignoreCase
.of
(ExampleMatcher.StringMatcher stringMatcher) Creates a newExampleMatcher.GenericPropertyMatcher
with aExampleMatcher.StringMatcher
andignoreCase
.of
(ExampleMatcher.StringMatcher stringMatcher, boolean ignoreCase) Creates a newExampleMatcher.GenericPropertyMatcher
with aExampleMatcher.StringMatcher
andignoreCase
.regex()
Sets string matcher toExampleMatcher.StringMatcher.REGEX
.Sets string matcher toExampleMatcher.StringMatcher.STARTING
.Sets string matcher toExampleMatcher.StringMatcher.DEFAULT
.stringMatcher
(ExampleMatcher.StringMatcher stringMatcher) Sets string matcher tostringMatcher
.transform
(ExampleMatcher.PropertyValueTransformer propertyValueTransformer) Sets theExampleMatcher.PropertyValueTransformer
topropertyValueTransformer
.
-
Constructor Details
-
GenericPropertyMatcher
public GenericPropertyMatcher()Creates an unconfiguredExampleMatcher.GenericPropertyMatcher
.
-
-
Method Details
-
of
public static ExampleMatcher.GenericPropertyMatcher of(ExampleMatcher.StringMatcher stringMatcher, boolean ignoreCase) Creates a newExampleMatcher.GenericPropertyMatcher
with aExampleMatcher.StringMatcher
andignoreCase
.- Parameters:
stringMatcher
- must not be null.ignoreCase
-- Returns:
-
of
Creates a newExampleMatcher.GenericPropertyMatcher
with aExampleMatcher.StringMatcher
andignoreCase
.- Parameters:
stringMatcher
- must not be null.- Returns:
-
ignoreCase
Sets ignores case to true.- Returns:
-
ignoreCase
Sets ignores case toignoreCase
.- Parameters:
ignoreCase
-- Returns:
-
caseSensitive
Sets ignores case to false.- Returns:
-
contains
Sets string matcher toExampleMatcher.StringMatcher.CONTAINING
.- Returns:
-
endsWith
Sets string matcher toExampleMatcher.StringMatcher.ENDING
.- Returns:
-
startsWith
Sets string matcher toExampleMatcher.StringMatcher.STARTING
.- Returns:
-
exact
Sets string matcher toExampleMatcher.StringMatcher.EXACT
.- Returns:
-
storeDefaultMatching
Sets string matcher toExampleMatcher.StringMatcher.DEFAULT
.- Returns:
-
regex
Sets string matcher toExampleMatcher.StringMatcher.REGEX
.- Returns:
-
stringMatcher
public ExampleMatcher.GenericPropertyMatcher stringMatcher(ExampleMatcher.StringMatcher stringMatcher) Sets string matcher tostringMatcher
.- Parameters:
stringMatcher
- must not be null.- Returns:
-
transform
public ExampleMatcher.GenericPropertyMatcher transform(ExampleMatcher.PropertyValueTransformer propertyValueTransformer) Sets theExampleMatcher.PropertyValueTransformer
topropertyValueTransformer
.- Parameters:
propertyValueTransformer
- must not be null.- Returns:
-
canEqual
-
equals
-
hashCode
public int hashCode()
-