Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes15kdownloads
implementations.cpython-313.pyc140 linesDownload Raw Back to __pycache__
1�

2��js0�	��SrSSKrSSKrSSKJr SSKJr SSKJr SSKJr SSKJr SSK	J3r4 SS	KJr \Rr
\Rr\RrSS5jrSr\R$r\R&r\R(r"SS
\5rSrSr"SS\5r\"SSSSSS5rSSjrSSjrSSjr\R<r\R>r"SS\5r \ "SSSSSSS5r!SSjr"SSjr#g)z.Entry points into the Beta API of gRPC Python.�N)�_auth)�_client_adaptations)�	_metadata)�_server_adaptations)�6interfaces)�cardinality)�facec�8^�U4Sjn[R"X!S9$)Nc�$>^�U4SjnT"X5 g)Nc�@>�T"[R"U5U5 g�N)r�unbeta)�
beta_metadata�error�callbacks  ��_D:\code\apps\devtools\python\user_packages\Python313\site-packages\grpc/beta/implementations.py�wrapped_callback�Cmetadata_call_credentials.<locals>.plugin.<locals>.wrapped_callback's����Y�%�%�m�4�e�<��)�contextrr�metadata_plugins ` �r�plugin�)metadata_call_credentials.<locals>.plugin&s���	=�	��2r)�name)�grpc�metadata_call_credentials)rrrs`  rrr%s���3��)�)�&�<�<rc�@�[[R"U55$)z�Construct CallCredentials from GoogleCredentials.7 8Args:9  credentials: A GoogleCredentials object from the oauth2client library.10 11Returns:12  A CallCredentials object for use in a GRPCCallOptions object.13)rr�GoogleCallCredentials)�credentialss r�google_call_credentialsr!/s��%�U�%@�%@��%M�N�Nrc�.�\rSrSrSrSrSSjrSrSrg)	�Channel�@z�A channel to a remote host through which RPCs may be conducted.14 15Only the "subscribe" and "unsubscribe" methods are supported for application16use. This class' instance constructor and all other attributes are17unsupported.18c��Xlgr
��_channel)�self�channels  r�__init__�Channel.__init__Hs���
rNc�6�URRXS9 g)a�Subscribes to this Channel's connectivity.19 20Args:21  callback: A callable to be invoked and passed an22    interfaces.ChannelConnectivity identifying this Channel's connectivity.23    The callable will be invoked immediately upon subscription and again for24    every change to this Channel's connectivity thereafter until it is25    unsubscribed.26  try_to_connect: A boolean indicating whether or not this Channel should27    attempt to connect if it is not already connected and ready to conduct28    RPCs.29)�try_to_connectN)r'�	subscribe)r(rr-s   rr.�Channel.subscribeKs��	
�
�
�����Hrc�:�URRU5 g)z�Unsubscribes a callback from this Channel's connectivity.30 31Args:32  callback: A callable previously registered with this Channel from having33    been passed to its "subscribe" method.34N)r'�unsubscribe)r(rs  rr1�Channel.unsubscribeZs��	
�
�
�!�!�(�+rr&r
)	�__name__�35__module__�__qualname__�__firstlineno__�__doc__r*r.r1�__static_attributes__rrrr#r#@s��� �
I�,rr#c�V�[R"UcUOSX4-5n[U5$)a$Creates an insecure Channel to a remote host.36 37Args:38  host: The name of the remote host to which to connect.39  port: The port of the remote host to which to connect.40    If None only the 'host' part will be used.41 42Returns:43  A Channel to the remote host through which RPCs may be conducted.44�%s:%d)r�insecure_channelr#)�host�portr)s   rr;r;ds1���#�#����'�T�L�"8��G��7��rc�X�[R"UcUOSX4-U5n[U5$)aUCreates a secure Channel to a remote host.45 46Args:47  host: The name of the remote host to which to connect.48  port: The port of the remote host to which to connect.49    If None only the 'host' part will be used.50  channel_credentials: A ChannelCredentials.51 52Returns:53  A secure Channel to the remote host through which RPCs may be conducted.54r:)r�secure_channelr#)r<r=�channel_credentialsr)s    rr?r?us4���!�!����'�T�L�"8�:M��G��7��rc��\rSrSrSrSrSrg)�StubOptions�z�A value encapsulating the various options for creation of a Stub.55 56This class and its instances have no supported interface - it exists to define57the type of its instances and its instances exist to be passed to other58functions.59c�L�XlX lX0lX@lXPlX`lgr
�r<�request_serializers�response_deserializers�metadata_transformer�thread_pool�thread_pool_size)r(r<rFrGrHrIrJs       rr*�StubOptions.__init__�s'���	�#6� �&<�#�$8�!�&�� 0�r)r<rHrFrGrIrJN�r3r4r5r6r7r*r8rrrrBrB�s���1rrBc�"�[UUUUUU5$)aCreates a StubOptions value to be passed at stub creation.60 61All parameters are optional and should always be passed by keyword.62 63Args:64  host: A host string to set on RPC calls.65  request_serializers: A dictionary from service name-method name pair to66    request serialization behavior.67  response_deserializers: A dictionary from service name-method name pair to68    response deserialization behavior.69  metadata_transformer: A callable that given a metadata object produces70    another metadata object to be used in the underlying communication on the71    wire.72  thread_pool: A thread pool to use in stubs.73  thread_pool_size: The size of thread pool to create for use in stubs;74    ignored if thread_pool has been passed.75 76Returns:77  A StubOptions value created from the passed parameters.78)rBrEs      r�stub_optionsrN�s#��8�������
�rc��Uc[OUn[R"URURUR79URUR5$)z�Creates a face.GenericStub on which RPCs can be made.80 81Args:82  channel: A Channel for use by the created stub.83  options: A StubOptions customizing the created stub.84 85Returns:86  A face.GenericStub on which RPCs can be made.87)�_EMPTY_STUB_OPTIONSr�generic_stubr'r<rHrFrG)r)�options�effective_optionss   rrQrQ�sQ��07��+�G���+�+��������.�.��-�-��0�0��rc	��Uc[OUn[R"URUUURUR88URUR5$)a�Creates a face.DynamicStub with which RPCs can be invoked.89 90Args:91  channel: A Channel for the returned face.DynamicStub to use.92  service: The package-qualified full name of the service.93  cardinalities: A dictionary from RPC method name to cardinality.Cardinality94    value identifying the cardinality of the RPC method.95  options: An optional StubOptions value further customizing the functionality96    of the returned face.DynamicStub.97 98Returns:99  A face.DynamicStub with which RPCs can be invoked.100)rPr�dynamic_stubr'r<rHrFrG)r)�service�
cardinalitiesrRrSs     rrUrU�sW��07��+�G���+�+����������.�.��-�-��0�0��rc��\rSrSrSrSrSrg)�
ServerOptions��z�A value encapsulating the various options for creation of a Server.101 102This class and its instances have no supported interface - it exists to define103the type of its instances and its instances exist to be passed to other104functions.105c�X�XlX lX0lX@lXPlX`lXplgr
��multi_method_implementation�request_deserializers�response_serializersrIrJ�default_timeout�maximum_timeout)r(r]r^r_rIrJr`ras        rr*�ServerOptions.__init__s/��,G�(�%:�"�$8�!�&�� 0��.��.�r)r`rar]r^r_rIrJNrLrrrrYrY�s���/rrYc	�$�[UUUUUUU5$)aTCreates a ServerOptions value to be passed at server creation.106 107All parameters are optional and should always be passed by keyword.108 109Args:110  multi_method_implementation: A face.MultiMethodImplementation to be called111    to service an RPC if the server has no specific method implementation for112    the name of the RPC for which service was requested.113  request_deserializers: A dictionary from service name-method name pair to114    request deserialization behavior.115  response_serializers: A dictionary from service name-method name pair to116    response serialization behavior.117  thread_pool: A thread pool to use in stubs.118  thread_pool_size: The size of thread pool to create for use in stubs;119    ignored if thread_pool has been passed.120  default_timeout: A duration in seconds to allow for RPC service when121    servicing RPCs that did not include a timeout value when invoked.122  maximum_timeout: A duration in seconds to allow for RPC service when123    servicing RPCs no matter what timeout value was passed when the RPC was124    invoked.125 126Returns:127  A StubOptions value created from the passed parameters.128)rYr\s       r�server_optionsrds'��B�#��������rc��Uc[OUn[R"UURURUR129URUR5$)aaCreates an interfaces.Server with which RPCs can be serviced.130 131Args:132  service_implementations: A dictionary from service name-method name pair to133    face.MethodImplementation.134  options: An optional ServerOptions value further customizing the135    functionality of the returned Server.136 137Returns:138  An interfaces.Server with which RPCs can be serviced.139)�_EMPTY_SERVER_OPTIONSr�serverr]r^r_rIrJ)�service_implementationsrRrSs   rrgrgEsT��29��-�g���%�%���5�5��/�/��.�.��%�%��*�*�
�rr
)NNNNNN)NNNNNNN)$r7�	threadingrr�	grpc.betarrrr�grpc.framework.commonr�grpc.framework.interfaces.facer	�ChannelCredentials�ssl_channel_credentials�CallCredentialsrr!�access_token_call_credentials�composite_call_credentials�composite_channel_credentials�objectr#r;r?rBrPrNrQrU�ServerCredentials�ssl_server_credentialsrYrfrdrgrrr�<module>rvs>��5����)��)� �-�/��,�,���6�6���&�&��=�	O�!%� B� B��!�<�<�� $� B� B��!,�f�!,�H�"�$1�&�1�2"�$��d�D�$��E��140������
#�L�(�4�*�*���4�4��/�F�/�6&�d�D�$��d�D�$�O��!%�������)�Xr
codekingpro/portable-devtools · Team Ai