@@ -80,7 +80,7 @@ public class UserCredentials {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the password in obfuscated fashion which means everthing except the first and last character replaced by
|
||||
* Returns the password in obfuscated fashion which means everything except the first and last character replaced by
|
||||
* stars. If the password is one or two characters long we'll obfuscate it entirely.
|
||||
*
|
||||
* @return the obfuscated password
|
||||
|
||||
@@ -106,7 +106,7 @@ public class TypeFilterParser {
|
||||
}
|
||||
|
||||
/**
|
||||
* Createsa a {@link TypeFilter} instance from the given {@link Element} and {@link ClassLoader}.
|
||||
* Creates a {@link TypeFilter} instance from the given {@link Element} and {@link ClassLoader}.
|
||||
*
|
||||
* @param element must not be {@literal null}.
|
||||
* @param classLoader must not be {@literal null}.
|
||||
@@ -171,8 +171,8 @@ public class TypeFilterParser {
|
||||
|
||||
Class<?> filterClass = classLoader.loadClass(expression);
|
||||
if (!TypeFilter.class.isAssignableFrom(filterClass)) {
|
||||
throw new IllegalArgumentException("Class is not assignable to [" + TypeFilter.class.getName() + "]: "
|
||||
+ expression);
|
||||
throw new IllegalArgumentException(
|
||||
"Class is not assignable to [" + TypeFilter.class.getName() + "]: " + expression);
|
||||
}
|
||||
return (TypeFilter) BeanUtils.instantiateClass(filterClass);
|
||||
}
|
||||
|
||||
@@ -187,7 +187,7 @@ public class Sort implements Streamable<org.springframework.data.domain.Sort.Ord
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a new {@link Sort} with the current setup but ascendin order direction.
|
||||
* Returns a new {@link Sort} with the current setup but ascending order direction.
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -30,9 +30,10 @@ public enum Metrics implements Metric {
|
||||
private final String abbreviation;
|
||||
|
||||
/**
|
||||
* Creates a new {@link Metrics} using the given muliplier.
|
||||
* Creates a new {@link Metrics} using the given multiplier.
|
||||
*
|
||||
* @param multiplier the earth radius at equator.
|
||||
* @param multiplier the earth radius at equator, must not be {@literal null}.
|
||||
* @param abbreviation the abbreviation to use for this {@link Metric}, must not be {@literal null}.
|
||||
*/
|
||||
private Metrics(double multiplier, String abbreviation) {
|
||||
|
||||
|
||||
@@ -102,7 +102,7 @@ public interface QuerydslPredicateExecutor<T> {
|
||||
/**
|
||||
* Checks whether the data store contains elements that match the given {@link Predicate}.
|
||||
*
|
||||
* @param predicate the {@link Predicate} to use for the existance check, can be {@literal null}.
|
||||
* @param predicate the {@link Predicate} to use for the existence check, can be {@literal null}.
|
||||
* @return {@literal true} if the data store contains elements that match the given {@link Predicate}.
|
||||
*/
|
||||
boolean exists(Predicate predicate);
|
||||
|
||||
@@ -33,7 +33,7 @@ import java.lang.annotation.Target;
|
||||
public @interface QuerydslPredicate {
|
||||
|
||||
/**
|
||||
* The root type to create the {@link com.mysema.query.types.Predicate}. Specify this explictly if the type is not
|
||||
* The root type to create the {@link com.mysema.query.types.Predicate}. Specify this explicitly if the type is not
|
||||
* contained in the controller method's return type.
|
||||
*
|
||||
* @return
|
||||
|
||||
@@ -32,10 +32,10 @@ import org.springframework.data.repository.PagingAndSortingRepository;
|
||||
public interface CrudMethods {
|
||||
|
||||
/**
|
||||
* Returns the method to be used for saving entities. Usually siganture compatible to
|
||||
* Returns the method to be used for saving entities. Usually signature compatible to
|
||||
* {@link CrudRepository#save(Object)}.
|
||||
*
|
||||
* @return the method to save entities or {@literal null} if noen exposed.
|
||||
* @return the method to save entities or {@literal null} if none exposed.
|
||||
* @see #hasSaveMethod()
|
||||
*/
|
||||
Optional<Method> getSaveMethod();
|
||||
@@ -48,7 +48,7 @@ public interface CrudMethods {
|
||||
boolean hasSaveMethod();
|
||||
|
||||
/**
|
||||
* Returns the find all method of the repository. Implementations should prefer more detailled methods like
|
||||
* Returns the find all method of the repository. Implementations should prefer more detailed methods like
|
||||
* {@link PagingAndSortingRepository}'s taking a {@link Pageable} or {@link Sort} instance.
|
||||
*
|
||||
* @return the find all method of the repository or {@literal null} if not available.
|
||||
@@ -88,7 +88,7 @@ public interface CrudMethods {
|
||||
Optional<Method> getDeleteMethod();
|
||||
|
||||
/**
|
||||
* Returns whether the repository esposes a delete method.
|
||||
* Returns whether the repository exposes a delete method.
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -60,7 +60,7 @@ public abstract class AbstractRepositoryMetadata implements RepositoryMetadata {
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositoryMetadata} for the given repsository interface.
|
||||
* Creates a new {@link RepositoryMetadata} for the given repository interface.
|
||||
*
|
||||
* @param repositoryInterface must not be {@literal null}.
|
||||
* @since 1.9
|
||||
|
||||
@@ -59,7 +59,7 @@ public class ResourceReaderRepositoryPopulator implements RepositoryPopulator, A
|
||||
}
|
||||
|
||||
/**
|
||||
* Createsa a new {@link ResourceReaderRepositoryPopulator} using the given {@link ResourceReader} and
|
||||
* Creates a new {@link ResourceReaderRepositoryPopulator} using the given {@link ResourceReader} and
|
||||
* {@link ClassLoader}.
|
||||
*
|
||||
* @param reader must not be {@literal null}.
|
||||
|
||||
@@ -88,7 +88,7 @@ public class QueryMethod {
|
||||
|
||||
if (hasParameterOfType(method, Sort.class)) {
|
||||
throw new IllegalStateException(String.format("Method must not have Pageable *and* Sort parameter. "
|
||||
+ "Use sorting capabilities on Pageble instead! Offending method: %s", method.toString()));
|
||||
+ "Use sorting capabilities on Pageable instead! Offending method: %s", method.toString()));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -106,7 +106,8 @@ public class QueryMethod {
|
||||
Class<?> methodDomainClass = metadata.getReturnedDomainClass(method);
|
||||
|
||||
return repositoryDomainClass == null || repositoryDomainClass.isAssignableFrom(methodDomainClass)
|
||||
? methodDomainClass : repositoryDomainClass;
|
||||
? methodDomainClass
|
||||
: repositoryDomainClass;
|
||||
});
|
||||
|
||||
this.resultProcessor = new ResultProcessor(this, factory);
|
||||
|
||||
@@ -68,7 +68,7 @@ public class Part {
|
||||
*/
|
||||
public Part(String source, Class<?> clazz, boolean alwaysIgnoreCase) {
|
||||
|
||||
Assert.hasText(source, "Part source must not be null or emtpy!");
|
||||
Assert.hasText(source, "Part source must not be null or empty!");
|
||||
Assert.notNull(clazz, "Type must not be null!");
|
||||
|
||||
String partToUse = detectAndSetIgnoreCase(source);
|
||||
@@ -150,14 +150,16 @@ public class Part {
|
||||
|
||||
BETWEEN(2, "IsBetween", "Between"), IS_NOT_NULL(0, "IsNotNull", "NotNull"), IS_NULL(0, "IsNull", "Null"), LESS_THAN(
|
||||
"IsLessThan", "LessThan"), LESS_THAN_EQUAL("IsLessThanEqual", "LessThanEqual"), GREATER_THAN("IsGreaterThan",
|
||||
"GreaterThan"), GREATER_THAN_EQUAL("IsGreaterThanEqual", "GreaterThanEqual"), BEFORE("IsBefore", "Before"), AFTER(
|
||||
"IsAfter", "After"), NOT_LIKE("IsNotLike", "NotLike"), LIKE("IsLike", "Like"), STARTING_WITH("IsStartingWith",
|
||||
"StartingWith", "StartsWith"), ENDING_WITH("IsEndingWith", "EndingWith", "EndsWith"), IS_NOT_EMPTY(0, "IsNotEmpty",
|
||||
"NotEmpty"), IS_EMPTY(0, "IsEmpty", "Empty"), NOT_CONTAINING("IsNotContaining", "NotContaining", "NotContains"),
|
||||
CONTAINING("IsContaining", "Containing", "Contains"), NOT_IN("IsNotIn", "NotIn"), IN("IsIn", "In"), NEAR("IsNear",
|
||||
"Near"), WITHIN("IsWithin", "Within"), REGEX("MatchesRegex", "Matches", "Regex"), EXISTS(0, "Exists"), TRUE(0,
|
||||
"IsTrue", "True"), FALSE(0, "IsFalse", "False"), NEGATING_SIMPLE_PROPERTY("IsNot", "Not"), SIMPLE_PROPERTY("Is",
|
||||
"Equals");
|
||||
"GreaterThan"), GREATER_THAN_EQUAL("IsGreaterThanEqual", "GreaterThanEqual"), BEFORE("IsBefore",
|
||||
"Before"), AFTER("IsAfter", "After"), NOT_LIKE("IsNotLike", "NotLike"), LIKE("IsLike",
|
||||
"Like"), STARTING_WITH("IsStartingWith", "StartingWith", "StartsWith"), ENDING_WITH("IsEndingWith",
|
||||
"EndingWith", "EndsWith"), IS_NOT_EMPTY(0, "IsNotEmpty", "NotEmpty"), IS_EMPTY(0, "IsEmpty",
|
||||
"Empty"), NOT_CONTAINING("IsNotContaining", "NotContaining", "NotContains"), CONTAINING(
|
||||
"IsContaining", "Containing", "Contains"), NOT_IN("IsNotIn", "NotIn"), IN("IsIn",
|
||||
"In"), NEAR("IsNear", "Near"), WITHIN("IsWithin", "Within"), REGEX("MatchesRegex",
|
||||
"Matches", "Regex"), EXISTS(0, "Exists"), TRUE(0, "IsTrue", "True"), FALSE(0,
|
||||
"IsFalse", "False"), NEGATING_SIMPLE_PROPERTY("IsNot",
|
||||
"Not"), SIMPLE_PROPERTY("Is", "Equals");
|
||||
|
||||
// Need to list them again explicitly as the order is important
|
||||
// (esp. for IS_NULL, IS_NOT_NULL)
|
||||
|
||||
@@ -48,7 +48,7 @@ public class NullableWrapper {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the backing valie
|
||||
* Returns the backing value.
|
||||
*
|
||||
* @return the value can be {@literal null}.
|
||||
*/
|
||||
|
||||
@@ -193,7 +193,7 @@ public class PageableHandlerMethodArgumentResolver implements PageableArgumentRe
|
||||
* The delimiter to be used between the qualifier and the actual page number and size properties. Defaults to
|
||||
* {@code _}. So a qualifier of {@code foo} will result in a page number parameter of {@code foo_page}.
|
||||
*
|
||||
* @param qualifierDelimiter the delimter to be used or {@literal null} to reset to the default.
|
||||
* @param qualifierDelimiter the delimiter to be used or {@literal null} to reset to the default.
|
||||
*/
|
||||
public void setQualifierDelimiter(String qualifierDelimiter) {
|
||||
this.qualifierDelimiter = qualifierDelimiter == null ? DEFAULT_QUALIFIER_DELIMITER : qualifierDelimiter;
|
||||
|
||||
Reference in New Issue
Block a user