
    Bf                         U d Z ddlZddlmZ ddlmZ  ej                    Zej	        Z
eedf         ed<   	 ddlZej	        Zn# e$ r dZY nw xY w G d de          ZdS )zHelpers for providing client information.

Client information is used to send information about the calling client,
such as the library and Python version, to API services.
    N)Union)version_GRPC_VERSIONc                   .    e Zd ZdZeeeddddfdZd ZdS )
ClientInfoa  Client information used to generate a user-agent for API calls.

    This user-agent information is sent along with API calls to allow the
    receiving service to do analytics on which versions of Python and Google
    libraries are being used.

    Args:
        python_version (str): The Python interpreter version, for example,
            ``'3.9.6'``.
        grpc_version (Optional[str]): The gRPC library version.
        api_core_version (str): The google-api-core library version.
        gapic_version (Optional[str]): The version of gapic-generated client
            library, if the library was generated by gapic.
        client_library_version (Optional[str]): The version of the client
            library, generally used if the client library was not generated
            by gapic or if additional functionality was built on top of
            a gapic client library.
        user_agent (Optional[str]): Prefix to the user agent header. This is
            used to supply information such as application name or partner tool.
            Recommended format: ``application-or-tool-ID/major.minor.version``.
        rest_version (Optional[str]): The requests library version.
    Nc                 h    || _         || _        || _        || _        || _        || _        || _        d S )N)python_versiongrpc_versionapi_core_versiongapic_versionclient_library_version
user_agentrest_version)selfr	   r
   r   r   r   r   r   s           j/home/panchajanya/Development/work/volatility3/lib/python3.11/site-packages/google/api_core/client_info.py__init__zClientInfo.__init__?   sA     -( 0*&<#$(    c                     d}| j         |dz  }|dz  }| j        |dz  }| j        |dz  }|dz  }| j        |dz  }| j        |d	z  } |j        d
i | j                                        S )z3Returns the user-agent string for this client info. Nz{user_agent} zgl-python/{python_version} zgrpc/{grpc_version} zrest/{rest_version} zgax/{api_core_version} zgapic/{gapic_version} zgccl/{client_library_version}  )r   r
   r   r   r   format__dict__strip)r   uas     r   to_user_agentzClientInfo.to_user_agentQ   s    
 ?&/!B
++(((B(((B
'')**B&222Bry))4=))//111r   )	__name__
__module____qualname____doc___PY_VERSIONr   _API_CORE_VERSIONr   r   r   r   r   r   r   '   sX         2 #"*#) ) ) )$2 2 2 2 2r   r   )r   platformtypingr   google.api_corer   r   r	   r    __version__r!   str__annotations__grpcr   ImportErrorobjectr   r   r   r   <module>r+      s             7 7 7 7 7 7%h%''$0 S$Y   KKK$MM   MMMD2 D2 D2 D2 D2 D2 D2 D2 D2 D2s   A AA