Remove unnecessary generic type arguments

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=175155365
This commit is contained in:
mcilwain 2017-11-09 07:33:40 -08:00 committed by jianglai
parent 8dcc2d6833
commit 2aa897e698
140 changed files with 355 additions and 465 deletions

View file

@ -132,7 +132,7 @@ public abstract class BaseDomainLabelList<T extends Comparable<?>, R extends Dom
} else {
line = line.trim();
}
return line.isEmpty() ? ImmutableList.<String>of() : ImmutableList.<String>of(line, comment);
return line.isEmpty() ? ImmutableList.of() : ImmutableList.of(line, comment);
}
/** Gets the names of the tlds that reference this list. */

View file

@ -73,7 +73,7 @@ public final class PremiumListUtils {
public static Optional<Money> getPremiumPrice(String label, Registry registry) {
// If the registry has no configured premium list, then no labels are premium.
if (registry.getPremiumList() == null) {
return Optional.<Money>empty();
return Optional.empty();
}
DateTime startTime = DateTime.now(UTC);
String listName = registry.getPremiumList().getName();
@ -103,7 +103,7 @@ public final class PremiumListUtils {
private static CheckResults checkStatus(PremiumListRevision premiumListRevision, String label) {
if (!premiumListRevision.getProbablePremiumLabels().mightContain(label)) {
return CheckResults.create(BLOOM_FILTER_NEGATIVE, Optional.<Money>empty());
return CheckResults.create(BLOOM_FILTER_NEGATIVE, Optional.empty());
}
Key<PremiumListEntry> entryKey =
@ -115,7 +115,7 @@ public final class PremiumListUtils {
if (entry.isPresent()) {
return CheckResults.create(CACHED_POSITIVE, Optional.of(entry.get().getValue()));
} else {
return CheckResults.create(CACHED_NEGATIVE, Optional.<Money>empty());
return CheckResults.create(CACHED_NEGATIVE, Optional.empty());
}
}
@ -123,7 +123,7 @@ public final class PremiumListUtils {
if (entry.isPresent()) {
return CheckResults.create(UNCACHED_POSITIVE, Optional.of(entry.get().getValue()));
} else {
return CheckResults.create(UNCACHED_NEGATIVE, Optional.<Money>empty());
return CheckResults.create(UNCACHED_NEGATIVE, Optional.empty());
}
} catch (InvalidCacheLoadException | ExecutionException e) {
throw new RuntimeException("Could not load premium list entry " + entryKey, e);