• Create a new ITraceParent instance using the provided values.

    Parameters

    • OptionaltraceId: string

      The traceId to use, when invalid a new random W3C id will be generated.

    • OptionalspanId: string

      The parent/span id to use, a new random value will be generated if it is invalid.

    • Optionalflags: number

      The traceFlags to use, defaults to zero (0) if not supplied or invalid

    • Optionalversion: string

      The version to used, defaults to version "01" if not supplied or invalid.

    Returns ITraceParent