Commit ca25ceb7 by xmh

分数降序

1 parent ce7fe5c5
...@@ -212,7 +212,7 @@ public class PersonService { ...@@ -212,7 +212,7 @@ public class PersonService {
matchBody(bodyFeatures, poolId, matchResult); matchBody(bodyFeatures, poolId, matchResult);
} }
Stream<Person> stream = matchResult.stream().sorted(Comparator.comparingInt(Person::getScore)); Stream<Person> stream = matchResult.stream().sorted(Comparator.comparingInt(Person::getScore).reversed());
if (matchResult.size() > Constant.MATCH_RESULT_SIZE) { if (matchResult.size() > Constant.MATCH_RESULT_SIZE) {
stream = stream.limit(5); stream = stream.limit(5);
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!