Skip to content

Commit 3f3afc4

Browse files
committed
No logical changes: Use Java 8 instead of guava
1 parent 07b7b54 commit 3f3afc4

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

java/client/src/org/openqa/selenium/logging/StoringLocalLogs.java

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,8 @@
1717

1818
package org.openqa.selenium.logging;
1919

20-
import com.google.common.collect.Lists;
21-
import com.google.common.collect.Maps;
22-
20+
import java.util.ArrayList;
21+
import java.util.HashMap;
2322
import java.util.List;
2423
import java.util.Map;
2524
import java.util.Set;
@@ -29,7 +28,7 @@
2928
* of logs, such as for profiling.
3029
*/
3130
class StoringLocalLogs extends LocalLogs {
32-
private final Map<String, List<LogEntry>> localLogs = Maps.newHashMap();
31+
private final Map<String, List<LogEntry>> localLogs = new HashMap<>();
3332
private final Set<String> logTypesToInclude;
3433

3534
public StoringLocalLogs(Set<String> logTypesToInclude) {
@@ -43,11 +42,11 @@ public LogEntries get(String logType) {
4342
private Iterable<LogEntry> getLocalLogs(String logType) {
4443
if (localLogs.containsKey(logType)) {
4544
List<LogEntry> entries = localLogs.get(logType);
46-
localLogs.put(logType, Lists.<LogEntry>newArrayList());
45+
localLogs.put(logType, new ArrayList<>());
4746
return entries;
4847
}
4948

50-
return Lists.newArrayList();
49+
return new ArrayList<>();
5150
}
5251

5352
/**
@@ -62,7 +61,7 @@ public void addEntry(String logType, LogEntry entry) {
6261
}
6362

6463
if (!localLogs.containsKey(logType)) {
65-
localLogs.put(logType, Lists.newArrayList(entry));
64+
localLogs.put(logType, new ArrayList<>());
6665
} else {
6766
localLogs.get(logType).add(entry);
6867
}

0 commit comments

Comments
 (0)