§
    xŠtjˆ	  ã                   ód   — d dl Z d dlZd dlmZ  G d„ de j        ¦  «        Z G d„ de¦  «        ZdS )é    N)Útracec                   óf   — e Zd Zej        defd„¦   «         Zej        defd„¦   «         Zdefd„Z	dS )ÚIdGeneratorÚreturnc                 ó   — dS )z[Get a new span ID.

        Returns:
            A 64-bit int for use as a span ID
        N© ©Úselfs    úb/var/www/html/CA-Chatbot/venv/lib/python3.11/site-packages/opentelemetry/sdk/trace/id_generator.pyÚgenerate_span_idzIdGenerator.generate_span_id   ó   € € € ó    c                 ó   — dS )ax  Get a new trace ID.

        Implementations should at least make the 56 least significant bits
        uniformly random. Samplers like the `TraceIdRatioBased` sampler rely on
        this randomness to make sampling decisions.

        If the implementation does randomly generate the 56 least significant bits,
        it should also implement `is_trace_id_random` to return True.

        See `the specification on TraceIdRatioBased <https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/sdk.md#traceidratiobased>`_.

        Returns:
            A 128-bit int for use as a trace ID
        Nr   r	   s    r   Úgenerate_trace_idzIdGenerator.generate_trace_id   r   r   c                 ó   — dS )aR  Indicates whether generated trace IDs are random.

        When True, the `trace-id` field will have the `random-trace-id` flag set
        in the W3C traceparent header. Per the W3C Trace Context specification,
        this indicates that at least the 7 rightmost bytes (56 bits) of the
        trace ID were generated randomly with uniform distribution.

        See `the W3C Trace Context specification <https://www.w3.org/TR/trace-context-2/#considerations-for-trace-id-field-generation>`_.

        Returns:
            True if this generator produces random IDs, False otherwise.
        Fr   r	   s    r   Úis_trace_id_randomzIdGenerator.is_trace_id_random%   s	   € ð ˆur   N)
Ú__name__Ú
__module__Ú__qualname__ÚabcÚabstractmethodÚintr   r   Úboolr   r   r   r   r   r   
   sƒ   € € € € € ØÔð #ð ð ð ñ Ôðð 	Ôð 3ð ð ð ñ Ôðð" Dð ð ð ð ð ð r   r   c                   ó6   — e Zd ZdZdefd„Zdefd„Zdefd„ZdS )ÚRandomIdGeneratorzkThe default ID generator for TracerProvider which randomly generates all
    bits when generating IDs.
    r   c                 ó–   — t          j        d¦  «        }|t          j        k    r$t          j        d¦  «        }|t          j        k    °$|S )Né@   )ÚrandomÚgetrandbitsr   ÚINVALID_SPAN_ID)r
   Úspan_ids     r   r   z"RandomIdGenerator.generate_span_id;   sE   € ÝÔ$ RÑ(Ô(ˆØ�Ô.Ò.Ð.ÝÔ(¨Ñ,Ô,ˆGð �Ô.Ò.Ð.àˆr   c                 ó–   — t          j        d¦  «        }|t          j        k    r$t          j        d¦  «        }|t          j        k    °$|S )Né€   )r   r   r   ÚINVALID_TRACE_ID)r
   Útrace_ids     r   r   z#RandomIdGenerator.generate_trace_idA   sE   € ÝÔ% cÑ*Ô*ˆØ�%Ô0Ò0Ð0ÝÔ)¨#Ñ.Ô.ˆHð �%Ô0Ò0Ð0àˆr   c                 ó   — dS )NTr   r	   s    r   r   z$RandomIdGenerator.is_trace_id_randomG   s   € Øˆtr   N)	r   r   r   Ú__doc__r   r   r   r   r   r   r   r   r   r   6   so   € € € € € ðð ð #ð ð ð ð ð 3ð ð ð ð ð Dð ð ð ð ð ð r   r   )r   r   Úopentelemetryr   ÚABCr   r   r   r   r   ú<module>r*      sŒ   ðð €
€
€
Ø €€€à Ð Ð Ð Ð Ð ð)ð )ð )ð )ð )�#”'ñ )ô )ð )ðXð ð ð ð ˜ñ ô ð ð ð r   