Remove redundant type argument conversion (#1734)

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
This commit is contained in:
Bogdan Drutu 2020-10-01 18:41:56 -07:00 committed by GitHub
parent 0746ddbf68
commit 391043fa1f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 6 deletions

View File

@ -117,7 +117,7 @@ public abstract class TraceState {
// Needs to be in this class to avoid initialization deadlock because super class depends on
// subclass (the auto-value generate class).
private static final TraceState EMPTY = create(Collections.<Entry>emptyList());
private static final TraceState EMPTY = create(Collections.emptyList());
private Builder(TraceState parent) {
Utils.checkNotNull(parent, "parent");

View File

@ -89,7 +89,7 @@ public class MultiSpanExporterBenchmark {
.setHasEnded(true)
.build();
}
this.spans = Arrays.<SpanData>asList(spans);
this.spans = Arrays.asList(spans);
}
@Benchmark

View File

@ -81,8 +81,7 @@ public abstract class ResourcesConfig {
* @return a new {@link Builder}.
*/
public static Builder newBuilder() {
return new AutoValue_ResourcesConfig.Builder()
.setDisabledResourceProviders(ImmutableSet.<String>of());
return new AutoValue_ResourcesConfig.Builder().setDisabledResourceProviders(ImmutableSet.of());
}
/**

View File

@ -50,10 +50,10 @@ public abstract class TestSpanData implements SpanData {
return new AutoValue_TestSpanData.Builder()
.setParentSpanId(SpanId.getInvalid())
.setInstrumentationLibraryInfo(InstrumentationLibraryInfo.getEmpty())
.setLinks(Collections.<Link>emptyList())
.setLinks(Collections.emptyList())
.setTotalRecordedLinks(0)
.setAttributes(Attributes.empty())
.setEvents(Collections.<Event>emptyList())
.setEvents(Collections.emptyList())
.setTotalRecordedEvents(0)
.setResource(Resource.getEmpty())
.setTraceState(TraceState.getDefault())