From 83ab340d3f112d0f6190e0499c08551ddcb169ed Mon Sep 17 00:00:00 2001 From: David Pursehouse Date: Fri, 20 May 2016 12:31:15 +0900 Subject: [PATCH] Remove redundant specification of type arguments Change-Id: I5b084440bae3ad66604acb7308426ba2119ce7f3 --- .../java/com/google/gerrit/server/cache/h2/H2CacheImpl.java | 2 +- .../com/google/gerrit/client/change/RelatedChangesTab.java | 2 +- .../main/java/com/google/gerrit/server/project/GetReflog.java | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gerrit-cache-h2/src/main/java/com/google/gerrit/server/cache/h2/H2CacheImpl.java b/gerrit-cache-h2/src/main/java/com/google/gerrit/server/cache/h2/H2CacheImpl.java index 838f42c740..4d6db4d188 100644 --- a/gerrit-cache-h2/src/main/java/com/google/gerrit/server/cache/h2/H2CacheImpl.java +++ b/gerrit-cache-h2/src/main/java/com/google/gerrit/server/cache/h2/H2CacheImpl.java @@ -280,7 +280,7 @@ public class H2CacheImpl extends AbstractLoadingCache implements } } - final ValueHolder h = new ValueHolder(loader.call()); + final ValueHolder h = new ValueHolder<>(loader.call()); h.created = TimeUtil.nowMs(); executor.execute(new Runnable() { @Override diff --git a/gerrit-gwtui/src/main/java/com/google/gerrit/client/change/RelatedChangesTab.java b/gerrit-gwtui/src/main/java/com/google/gerrit/client/change/RelatedChangesTab.java index 791effc872..846ad53ba9 100644 --- a/gerrit-gwtui/src/main/java/com/google/gerrit/client/change/RelatedChangesTab.java +++ b/gerrit-gwtui/src/main/java/com/google/gerrit/client/change/RelatedChangesTab.java @@ -178,7 +178,7 @@ class RelatedChangesTab implements IsWidget { rows = new ArrayList<>(changes.length()); connectedPos = changes.length() - 1; connected = showIndirectAncestors - ? new HashSet(Math.max(changes.length() * 4 / 3, 16)) + ? new HashSet<>(Math.max(changes.length() * 4 / 3, 16)) : null; } diff --git a/gerrit-server/src/main/java/com/google/gerrit/server/project/GetReflog.java b/gerrit-server/src/main/java/com/google/gerrit/server/project/GetReflog.java index b957ba1ca9..1735c3dc49 100644 --- a/gerrit-server/src/main/java/com/google/gerrit/server/project/GetReflog.java +++ b/gerrit-server/src/main/java/com/google/gerrit/server/project/GetReflog.java @@ -89,8 +89,8 @@ public class GetReflog implements RestReadView { limit > 0 ? r.getReverseEntries(limit) : r.getReverseEntries(); } else { entries = limit > 0 - ? new ArrayList(limit) - : new ArrayList(); + ? new ArrayList<>(limit) + : new ArrayList<>(); for (ReflogEntry e : r.getReverseEntries()) { Timestamp timestamp = new Timestamp(e.getWho().getWhen().getTime()); if ((from == null || from.before(timestamp)) &&