sig/plugins/grpc.rbs in httpx-0.24.7 vs sig/plugins/grpc.rbs in httpx-1.0.0
- old
+ new
@@ -15,40 +15,10 @@
type grpc_request = untyped | _Each[untyped]
type grpc_response = untyped | _Each[untyped]
type credentials = Proc
- class Call
- attr_writer decoder: _Callable
-
- def metadata: () -> headers
-
- def trailing_metadata: () -> headers?
-
- private
-
- def initialize: (Response | StreamResponse response) -> untyped
-
- def grpc_response: () -> grpc_response
- end
-
- module Message
- def self?.unary: (response) -> grpc_message
-
- def self?.stream: (StreamResponse) { (String) -> void } -> void
- | (StreamResponse) -> Enumerable[String]
-
- def self?.encode: (String bytes, ?deflater: Compression::_Deflater?) -> String
-
- def self?.decode: (String message, encodings: Array[String], encoders: Hash[String, Compression::_Compressor]) -> String
- | (String message, encodings: Array[String], encoders: Hash[String, Compression::_Compressor]) { (String) -> void } -> void
-
- def self?.cancel: (Request) -> void
-
- def self?.verify_status: (StreamResponse | response) -> void
- end
-
interface _GRPCOptions
def grpc_service: () -> String?
def grpc_compression: () -> compression_option?
@@ -61,12 +31,12 @@
def self.extra_options: (Options) -> (Options & _GRPCOptions)
def self.load_dependencies: (singleton(Session)) -> void
module ResponseMethods
- def merge_headers: (headers_input trailers) -> void
+ attr_reader trailing_metadata: Hash[String, untyped]
- def encoders: () -> Hash[String, Compression::_Compressor]
+ def encoders: () -> Array[String | Encoding]
end
module InstanceMethods
def with_channel_credentials: (String ca_path, ?String? key, ?String? cert, **untyped) -> instance