Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add private constructors for stateless marshalers #6434

Merged
merged 1 commit into from
May 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
final class BoolAnyValueStatelessMarshaler implements StatelessMarshaler<Boolean> {
static final BoolAnyValueStatelessMarshaler INSTANCE = new BoolAnyValueStatelessMarshaler();

private BoolAnyValueStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, Boolean value, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
final class DoubleAnyValueStatelessMarshaler implements StatelessMarshaler<Double> {
static final DoubleAnyValueStatelessMarshaler INSTANCE = new DoubleAnyValueStatelessMarshaler();

private DoubleAnyValueStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, Double value, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
final class IntAnyValueStatelessMarshaler implements StatelessMarshaler<Long> {
static final IntAnyValueStatelessMarshaler INSTANCE = new IntAnyValueStatelessMarshaler();

private IntAnyValueStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, Long value, MarshalerContext context) throws IOException {
output.writeInt64(AnyValue.INT_VALUE, value);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
final class StringAnyValueStatelessMarshaler implements StatelessMarshaler<String> {
static final StringAnyValueStatelessMarshaler INSTANCE = new StringAnyValueStatelessMarshaler();

private StringAnyValueStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, String value, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ final class InstrumentationScopeSpansStatelessMarshaler
static final InstrumentationScopeSpansStatelessMarshaler INSTANCE =
new InstrumentationScopeSpansStatelessMarshaler();

private InstrumentationScopeSpansStatelessMarshaler() {}

@Override
public void writeTo(
Serializer output,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ public final class ResourceSpansStatelessMarshaler
private static final MarshalerContext.Key SCOPE_SPAN_WRITER_KEY = MarshalerContext.key();
private static final MarshalerContext.Key SCOPE_SPAN_SIZE_CALCULATOR_KEY = MarshalerContext.key();

private ResourceSpansStatelessMarshaler() {}

@Override
public void writeTo(
Serializer output,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
final class SpanEventStatelessMarshaler implements StatelessMarshaler<EventData> {
static final SpanEventStatelessMarshaler INSTANCE = new SpanEventStatelessMarshaler();

private SpanEventStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, EventData event, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
final class SpanLinkStatelessMarshaler implements StatelessMarshaler<LinkData> {
static final SpanLinkStatelessMarshaler INSTANCE = new SpanLinkStatelessMarshaler();

private SpanLinkStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, LinkData link, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
final class SpanStatelessMarshaler implements StatelessMarshaler<SpanData> {
static final SpanStatelessMarshaler INSTANCE = new SpanStatelessMarshaler();

private SpanStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, SpanData span, MarshalerContext context)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
final class SpanStatusStatelessMarshaler implements StatelessMarshaler<StatusData> {
static final SpanStatusStatelessMarshaler INSTANCE = new SpanStatusStatelessMarshaler();

private SpanStatusStatelessMarshaler() {}

@Override
public void writeTo(Serializer output, StatusData status, MarshalerContext context)
throws IOException {
Expand Down
Loading