@@ -53,52 +53,86 @@ default ReadWriteLogRecord setAllAttributes(Attributes attributes) {
53
53
LogRecordData toLogRecordData ();
54
54
55
55
/**
56
- * Returns the value of a given attribute if it exists. This is the equivalent of calling
57
- * getAttributes().get(key)
56
+ * Returns the value of a given attribute if it exists. This is the equivalent of calling {@code
57
+ * getAttributes().get(key)}.
58
+ *
59
+ * @since 1.46.0
58
60
*/
59
61
@ Nullable
60
62
default <T > T getAttribute (AttributeKey <T > key ) {
61
63
return toLogRecordData ().getAttributes ().get (key );
62
64
}
63
65
64
- /** Returns the instrumentation scope that generated this log. */
66
+ /**
67
+ * Returns the instrumentation scope that generated this log.
68
+ *
69
+ * @since 1.46.0
70
+ */
65
71
default InstrumentationScopeInfo getInstrumentationScopeInfo () {
66
72
return toLogRecordData ().getInstrumentationScopeInfo ();
67
73
}
68
74
69
- /** Returns the timestamp at which the log record occurred, in epoch nanos. */
75
+ /**
76
+ * Returns the timestamp at which the log record occurred, in epoch nanos.
77
+ *
78
+ * @since 1.46.0
79
+ */
70
80
default long getTimestampEpochNanos () {
71
81
return toLogRecordData ().getTimestampEpochNanos ();
72
82
}
73
83
74
- /** Returns the timestamp at which the log record was observed, in epoch nanos. */
84
+ /**
85
+ * Returns the timestamp at which the log record was observed, in epoch nanos.
86
+ *
87
+ * @since 1.46.0
88
+ */
75
89
default long getObservedTimestampEpochNanos () {
76
90
return toLogRecordData ().getTimestampEpochNanos ();
77
91
}
78
92
79
- /** Return the span context for this log, or {@link SpanContext#getInvalid()} if unset. */
93
+ /**
94
+ * Return the span context for this log, or {@link SpanContext#getInvalid()} if unset.
95
+ *
96
+ * @since 1.46.0
97
+ */
80
98
default SpanContext getSpanContext () {
81
99
return toLogRecordData ().getSpanContext ();
82
100
}
83
101
84
- /** Returns the severity for this log, or {@link Severity#UNDEFINED_SEVERITY_NUMBER} if unset. */
102
+ /**
103
+ * Returns the severity for this log, or {@link Severity#UNDEFINED_SEVERITY_NUMBER} if unset.
104
+ *
105
+ * @since 1.46.0
106
+ */
85
107
default Severity getSeverity () {
86
108
return toLogRecordData ().getSeverity ();
87
109
}
88
110
89
- /** Returns the severity text for this log, or null if unset. */
111
+ /**
112
+ * Returns the severity text for this log, or null if unset.
113
+ *
114
+ * @since 1.46.0
115
+ */
90
116
@ Nullable
91
117
default String getSeverityText () {
92
118
return toLogRecordData ().getSeverityText ();
93
119
}
94
120
95
- /** Returns the {@link Value} representation of the log body, of null if unset. */
121
+ /**
122
+ * Returns the {@link Value} representation of the log body, of null if unset.
123
+ *
124
+ * @since 1.46.0
125
+ */
96
126
@ Nullable
97
127
default Value <?> getBodyValue () {
98
128
return toLogRecordData ().getBodyValue ();
99
129
}
100
130
101
- /** Returns the attributes for this log, or {@link Attributes#empty()} if unset. */
131
+ /**
132
+ * Returns the attributes for this log, or {@link Attributes#empty()} if unset.
133
+ *
134
+ * @since 1.46.0
135
+ */
102
136
default Attributes getAttributes () {
103
137
return toLogRecordData ().getAttributes ();
104
138
}
0 commit comments