Skip to content

Commit 0a9a810

Browse files
committed
DATAJPA-1622 - Polishing.
Reformat code. Qualify static method calls. Original pull request: #397.
1 parent afd76f8 commit 0a9a810

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/main/java/org/springframework/data/jpa/domain/Specification.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
*/
1616
package org.springframework.data.jpa.domain;
1717

18-
import static org.springframework.data.jpa.domain.SpecificationComposition.*;
19-
2018
import java.io.Serializable;
2119

2220
import javax.persistence.criteria.CriteriaBuilder;
@@ -51,7 +49,7 @@ public interface Specification<T> extends Serializable {
5149
static <T> Specification<T> not(@Nullable Specification<T> spec) {
5250

5351
return spec == null //
54-
? (root, query, builder) -> null//
52+
? (root, query, builder) -> null //
5553
: (root, query, builder) -> builder.not(spec.toPredicate(root, query, builder));
5654
}
5755

@@ -74,9 +72,8 @@ static <T> Specification<T> where(@Nullable Specification<T> spec) {
7472
* @return The conjunction of the specifications
7573
* @since 2.0
7674
*/
77-
7875
default Specification<T> and(@Nullable Specification<T> other) {
79-
return composed(this, other, CriteriaBuilder::and);
76+
return SpecificationComposition.composed(this, other, CriteriaBuilder::and);
8077
}
8178

8279
/**
@@ -87,7 +84,7 @@ default Specification<T> and(@Nullable Specification<T> other) {
8784
* @since 2.0
8885
*/
8986
default Specification<T> or(@Nullable Specification<T> other) {
90-
return composed(this, other, CriteriaBuilder::or);
87+
return SpecificationComposition.composed(this, other, CriteriaBuilder::or);
9188
}
9289

9390
/**

0 commit comments

Comments
 (0)