DATACMNS-399 - Support query prefix to designate repository query methods.

Extended PREFIX regex in PartTree to support the "query" prefix.

Original author: @jiming
Original pull request: #56.
This commit is contained in:
Thomas Darimont
2013-11-13 17:55:49 +01:00
committed by Oliver Gierke
parent ba89dc9bb4
commit eddb3323de
3 changed files with 16 additions and 3 deletions

View File

@@ -38,7 +38,7 @@ import org.springframework.util.StringUtils;
*/
public class PartTree implements Iterable<OrPart> {
private static final Pattern PREFIX_TEMPLATE = Pattern.compile("^(find|read|get|count)(\\p{Lu}.*?)??By");
private static final Pattern PREFIX_TEMPLATE = Pattern.compile("^(find|read|get|count|query)(\\p{Lu}.*?)??By");
/*
* We look for a pattern of: keyword followed by