Code enum

code.* attribute keys from the OpenTelemetry semantic-conventions attribute registry.

Inheritance
Implemented types
Available extensions

Values

codeColumn → const Code

Deprecated, use code.column.number

Examples: 16

Stability: development

const Code('code.column')
codeColumnNumber → const Code

The column number in code.file.path best representing the operation. It SHOULD point within the code unit named in code.function.name. This attribute MUST NOT be used on the Profile signal since the data is already captured in 'message Line'. This constraint is imposed to prevent redundancy and maintain data integrity.

Examples: 16

const Code('code.column.number')
codeFilePath → const Code

The source code file name that identifies the code unit as uniquely as possible (preferably an absolute file path). This attribute MUST NOT be used on the Profile signal since the data is already captured in 'message Function'. This constraint is imposed to prevent redundancy and maintain data integrity.

Examples: /usr/local/MyApplication/content_root/app/index.php

const Code('code.file.path')
codeFilepath → const Code

Deprecated, use code.file.path instead

Examples: /usr/local/MyApplication/content_root/app/index.php

Stability: development

const Code('code.filepath')
codeFunction → const Code

Deprecated, use code.function.name instead

Examples: serveRequest

Stability: development

const Code('code.function')
codeFunctionName → const Code

The method or function fully-qualified name without arguments. The value should fit the natural representation of the language runtime, which is also likely the same used within code.stacktrace attribute value. This attribute MUST NOT be used on the Profile signal since the data is already captured in 'message Function'. This constraint is imposed to prevent redundancy and maintain data integrity.

Examples: com.example.MyHttpService.serveRequest, GuzzleHttp\Client::transfer, fopen

const Code('code.function.name')
codeLineNumber → const Code

The line number in code.file.path best representing the operation. It SHOULD point within the code unit named in code.function.name. This attribute MUST NOT be used on the Profile signal since the data is already captured in 'message Line'. This constraint is imposed to prevent redundancy and maintain data integrity.

Examples: 42

const Code('code.line.number')
codeLineno → const Code

Deprecated, use code.line.number instead

Examples: 42

Stability: development

const Code('code.lineno')
codeNamespace → const Code

Deprecated, namespace is now included into code.function.name

Examples: com.example.MyHttpService

Stability: development

const Code('code.namespace')
codeStacktrace → const Code

A stacktrace as a string in the natural representation for the language runtime. The representation is identical to exception.stacktrace . This attribute MUST NOT be used on the Profile signal since the data is already captured in 'message Location'. This constraint is imposed to prevent redundancy and maintain data integrity.

Examples: at com.example.GenerateTrace.methodB(GenerateTrace.java:13)\n at com.example.GenerateTrace.methodA(GenerateTrace.java:9)\n at com.example.GenerateTrace.main(GenerateTrace.java:5)

const Code('code.stacktrace')

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
key String
The attribute key string as defined in the OpenTelemetry specification.
final
name String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMapEntry(Object value) MapEntry<String, Object>

Available on OTelSemantic, provided by the OTelSemanticExtension extension

Converts this semantic attribute and its value to a MapEntry.
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<Code>
A constant List of the values in this enum, in order of their declaration.