Public declaration syntax from forge-swift/Sources/ForgeCore/Telemetry.swift Original source SHA-256: 345305dd83ba85f70ad920ca0e60f319c88039d2753bb6dd5959116b7315943b Function bodies and constant values are omitted. This is not the complete implementation. Source line 17 public enum SpanAttribute: Codable, Sendable, Equatable Source line 25 public init(from decoder: Decoder) throws Source line 45 public func encode(to encoder: Encoder) throws Source line 57 public init(stringLiteral value: String) Source line 61 public init(integerLiteral value: Int64) Source line 65 public init(floatLiteral value: Double) Source line 69 public init(booleanLiteral value: Bool) Source line 75 public enum SpanStatus: Codable, Sendable, Equatable Source line 89 public init(from decoder: Decoder) throws Source line 108 public func encode(to encoder: Encoder) throws Source line 128 public struct ForgeSpan: Codable, Sendable Source line 130 public var name: String /// Span start time. public var startTime: Timestamp /// Span end time (set when span completes). public var endTime: Timestamp? /// Key-value attributes. public var attributes: [String: SpanAttribute] /// Span status. public var status: SpanStatus /// Parent span ID for distributed tracing. public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 132 public var startTime: Timestamp /// Span end time (set when span completes). public var endTime: Timestamp? /// Key-value attributes. public var attributes: [String: SpanAttribute] /// Span status. public var status: SpanStatus /// Parent span ID for distributed tracing. public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 134 public var endTime: Timestamp? /// Key-value attributes. public var attributes: [String: SpanAttribute] /// Span status. public var status: SpanStatus /// Parent span ID for distributed tracing. public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 136 public var attributes: [String: SpanAttribute] /// Span status. public var status: SpanStatus /// Parent span ID for distributed tracing. public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 138 public var status: SpanStatus /// Parent span ID for distributed tracing. public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 140 public var parentId: String? /// This span's unique ID. public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 142 public var spanId: String /// Creates a new span with the given name. Start time is set to now. /// /// - Parameter name: The span name (use dotted notation: "forge.agent.generate"). public init(name: String) Source line 147 public init(name: String) Source line 162 public mutating func setAttribute(_ key: String, _ value: SpanAttribute) Source line 167 public mutating func end() Source line 174 public mutating func endWithError(_ message: String) Source line 183 public func withParent(_ parentId: String) -> ForgeSpan Source line 196 public struct ForgeEvent: Codable, Sendable Source line 198 public var name: String /// When the event occurred. public var timestamp: Timestamp /// Key-value attributes. public var attributes: [String: SpanAttribute] /// Creates a new event with the given name. Timestamp is set to now. /// /// - Parameter name: The event name. public init(name: String) Source line 200 public var timestamp: Timestamp /// Key-value attributes. public var attributes: [String: SpanAttribute] /// Creates a new event with the given name. Timestamp is set to now. /// /// - Parameter name: The event name. public init(name: String) Source line 202 public var attributes: [String: SpanAttribute] /// Creates a new event with the given name. Timestamp is set to now. /// /// - Parameter name: The event name. public init(name: String) Source line 207 public init(name: String) Source line 218 public mutating func setAttribute(_ key: String, _ value: SpanAttribute) Source line 229 public protocol TelemetryEmitter: Sendable Source line 242 public struct NoopEmitter: TelemetryEmitter, Sendable Source line 243 public init() Source line 244 public func emitSpan(_ span: ForgeSpan) Source line 245 public func emitEvent(_ event: ForgeEvent) Source line 249 public final class RecordingEmitter: TelemetryEmitter, @unchecked Sendable Source line 254 public init() Source line 256 public func emitSpan(_ span: ForgeSpan) Source line 262 public func emitEvent(_ event: ForgeEvent) Source line 269 public var spans: [ForgeSpan] Source line 276 public var events: [ForgeEvent]