Package io.opentelemetry.sdk.logs.data
Class LogDataBuilder
java.lang.Object
io.opentelemetry.sdk.logs.data.LogDataBuilder
Builder for
LogData.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build aLogDatainstance from the configured properties.static LogDataBuildercreate(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo) Deprecated.static LogDataBuildercreate(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo, io.opentelemetry.sdk.common.Clock clock) Deprecated.static LogDataBuildercreate(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationScopeInfo instrumentationScopeInfo) Returns a newLogDataBuilderwith the default clock.static LogDataBuildercreate(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationScopeInfo instrumentationScopeInfo, io.opentelemetry.sdk.common.Clock clock) Returns a newLogDataBuilder.setAttributes(io.opentelemetry.api.common.Attributes attributes) Set the attributes.Set the body string.setContext(io.opentelemetry.context.Context context) Sets the context.Set the epoch timestamp using the timestamp and unit.Set the epoch timestamp using the instant.setSeverity(Severity severity) Set the severity.setSeverityText(String severityText) Set the severity text.setSpanContext(io.opentelemetry.api.trace.SpanContext spanContext) Sets the span context.
-
Method Details
-
create
@Deprecated public static LogDataBuilder create(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo) Deprecated.Returns a newLogDataBuilderwith the default clock. -
create
@Deprecated public static LogDataBuilder create(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo, io.opentelemetry.sdk.common.Clock clock) Deprecated.Returns a newLogDataBuilder. -
create
public static LogDataBuilder create(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationScopeInfo instrumentationScopeInfo) Returns a newLogDataBuilderwith the default clock. -
create
public static LogDataBuilder create(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationScopeInfo instrumentationScopeInfo, io.opentelemetry.sdk.common.Clock clock) Returns a newLogDataBuilder. -
setEpoch
Set the epoch timestamp using the timestamp and unit. -
setEpoch
Set the epoch timestamp using the instant. -
setContext
Sets the context. -
setSpanContext
Sets the span context. -
setSeverity
Set the severity. -
setSeverityText
Set the severity text. -
setBody
Set the body string. -
setAttributes
Set the attributes. -
build
Build aLogDatainstance from the configured properties.
-
create(Resource, InstrumentationScopeInfo).