Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to JDK 11 and Java 11 syntax [part 1] #698

Merged
merged 27 commits into from
Dec 10, 2021
Merged
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
f9553e6
Bump the version.
armiol Dec 8, 2021
140914e
Update to the latest `config`.
armiol Dec 8, 2021
384a1e1
Switch to Java 11 in the build script.
armiol Dec 8, 2021
f9dee8c
Update the report files.
armiol Dec 8, 2021
164174f
Update the code style.
armiol Dec 8, 2021
0c82d23
Run Java 11 on GitHub Actions.
armiol Dec 8, 2021
9704a74
Switch to Java 11 in IDEA.
armiol Dec 8, 2021
4ce66e6
Set `VariableTypeCanBeExplicit` to `WARNING`.
armiol Dec 8, 2021
29a119c
Set `RedundantExplicitVariableType` to `WARNING`. Turn off `VariableT…
armiol Dec 8, 2021
830e95c
Use `var`s in `io.spine.base` package.
armiol Dec 8, 2021
092d43d
Use `var`s in `io.spine.code` package and its subpackages.
armiol Dec 8, 2021
5e9ed3e
Use `var`s in `io.spine.environment` package.
armiol Dec 9, 2021
34c1da5
Use `var`s in `io.spine.io` package.
armiol Dec 9, 2021
bb07ef8
Use `var`s in `io.spine.json` package.
armiol Dec 9, 2021
588d972
Use `var`s in `io.spine.logging` package.
armiol Dec 9, 2021
a95f514
Use `var`s in `io.spine.protobuf` package.
armiol Dec 9, 2021
50cbe41
Use `var`s in `io.spine.query` package.
armiol Dec 9, 2021
b6407a8
Use `var`s in `io.spine.reflect` package.
armiol Dec 9, 2021
ad68e4b
Use `var`s in `io.spine.security` package.
armiol Dec 9, 2021
66fce09
Use `var`s in `io.spine.string` package.
armiol Dec 9, 2021
ca292f0
Use `var`s in `io.spine.type` package.
armiol Dec 9, 2021
a0f7862
Use `var`s in `io.spine.util` package.
armiol Dec 9, 2021
cc7d595
Use `var`s in `io.spine.validate` package and its subpackages.
armiol Dec 9, 2021
c966e3a
Use `var`s in `io.spine.value` package.
armiol Dec 9, 2021
e566365
Extract the "constant" part from the stream processing.
armiol Dec 10, 2021
57c384b
Reformat the ternary expression.
armiol Dec 10, 2021
b0b3737
Simplify the implementation.
armiol Dec 10, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Simplify the implementation.
armiol committed Dec 10, 2021
commit b0b373759eb32a4397eec0547a55920730a16cef
7 changes: 3 additions & 4 deletions base/src/main/java/io/spine/reflect/PackageGraph.java
Original file line number Diff line number Diff line change
@@ -137,9 +137,8 @@ private static Graph<PackageInfo> buildGraph(List<Package> packages) {
.nodeOrder(ElementOrder.<PackageInfo>natural())
.build();
Queue<Package> queue = new ArrayDeque<>(packages);
var first = queue.poll();
while (first != null) {
final var current = first;
var current = queue.poll();
while (current != null) {
var isDirectParent = IsDirectParent.of(current);
var directParent = graph.nodes().stream()
.filter((node) -> isDirectParent.test(node.getValue()))
@@ -150,7 +149,7 @@ private static Graph<PackageInfo> buildGraph(List<Package> packages) {
} else {
graph.addNode(newNode);
}
first = queue.poll();
current = queue.poll();
}
return graph;
}