mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-10-05 14:14:59 +00:00
* Use java 11 * Use .of - Replace Arrays.asList with List.of - Replace HashSet<>(List.of()) with Set.of * Formatting
This commit is contained in:
1 parent
dd971d8c19
commit
c8a481bb77
37 files changed
+176
-257
No files matched your search
@@ -24,8 +24,8 @@
|
||||
package com.iluwatar.retry;
|
||||
|
||||
import java.util.ArrayDeque;
|
||||
import java.util.Arrays;
|
||||
import java.util.Deque;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Finds a customer, returning its ID from our records.
|
||||
@@ -48,7 +48,7 @@ public final class FindCustomer implements BusinessOperation<String> {
|
||||
*/
|
||||
public FindCustomer(String customerId, BusinessException... errors) {
|
||||
this.customerId = customerId;
|
||||
this.errors = new ArrayDeque<>(Arrays.asList(errors));
|
||||
this.errors = new ArrayDeque<>(List.of(errors));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user