Remove redundant parentheses in lambda statements

Change-Id: I1e89aaea2d1a122fa3f13eb09cf7a2103540df57
This commit is contained in:
David Pursehouse
2020-02-19 17:42:07 +09:00
parent 2b4df55471
commit d77a118150
4 changed files with 5 additions and 5 deletions

View File

@@ -375,7 +375,7 @@ abstract class AbstractElasticIndex<K, V> implements Index<K, V> {
@Override
public ResultSet<V> read() throws OrmException {
return readImpl((doc) -> AbstractElasticIndex.this.fromDocument(doc, opts.fields()));
return readImpl(doc -> AbstractElasticIndex.this.fromDocument(doc, opts.fields()));
}
@Override

View File

@@ -498,12 +498,12 @@ public abstract class PermissionBackend {
public Set<LabelPermission.WithValue> testLabels(Collection<LabelType> types)
throws PermissionBackendException {
requireNonNull(types, "LabelType");
return test(types.stream().flatMap((t) -> valuesOf(t).stream()).collect(toSet()));
return test(types.stream().flatMap(t -> valuesOf(t).stream()).collect(toSet()));
}
private static Set<LabelPermission.WithValue> valuesOf(LabelType label) {
return label.getValues().stream()
.map((v) -> new LabelPermission.WithValue(label, v))
.map(v -> new LabelPermission.WithValue(label, v))
.collect(toSet());
}
}

View File

@@ -32,7 +32,7 @@ public abstract class RetryingRestCollectionModifyView<
@Override
public final O apply(P parentResource, I input)
throws AuthException, BadRequestException, ResourceConflictException, Exception {
return retryHelper.execute((updateFactory) -> applyImpl(updateFactory, parentResource, input));
return retryHelper.execute(updateFactory -> applyImpl(updateFactory, parentResource, input));
}
protected abstract O applyImpl(BatchUpdate.Factory updateFactory, P parentResource, I input)

View File

@@ -27,7 +27,7 @@ public abstract class RetryingRestModifyView<R extends RestResource, I, O>
@Override
public final O apply(R resource, I input) throws Exception {
return retryHelper.execute((updateFactory) -> applyImpl(updateFactory, resource, input));
return retryHelper.execute(updateFactory -> applyImpl(updateFactory, resource, input));
}
protected abstract O applyImpl(BatchUpdate.Factory updateFactory, R resource, I input)