Skip to content

Commit 8476e10

Browse files
mp911deapp
authored and
app
committed
Polishing.
Reformat code. Use explicit local variable types instead of var. See spring-projects#3075
1 parent dbdac10 commit 8476e10

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/main/java/org/springframework/data/domain/OffsetScrollPosition.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ static OffsetScrollPosition initial() {
6464
* @return will never be {@literal null}.
6565
*/
6666
static OffsetScrollPosition of(long offset) {
67+
6768
Assert.isTrue(offset >= 0, "Offset must not be negative");
6869
return new OffsetScrollPosition(offset);
6970
}
@@ -77,7 +78,6 @@ static OffsetScrollPosition of(long offset) {
7778
public static IntFunction<OffsetScrollPosition> positionFunction(long startOffset) {
7879

7980
Assert.isTrue(startOffset >= 0, "Start offset must not be negative");
80-
8181
return startOffset == 0 ? OffsetPositionFunction.ZERO : new OffsetPositionFunction(startOffset);
8282
}
8383

@@ -114,8 +114,7 @@ public long getOffset() {
114114
*/
115115
public OffsetScrollPosition advanceBy(long delta) {
116116

117-
var value = isInitial() ? delta : offset + delta;
118-
117+
long value = isInitial() ? delta : offset + delta;
119118
return new OffsetScrollPosition(value < 0 ? 0 : value);
120119
}
121120

0 commit comments

Comments
 (0)