sig/request.rbs in httpx-0.16.1 vs sig/request.rbs in httpx-0.17.0
- old
+ new
@@ -1,28 +1,29 @@
module HTTPX
class Request
+ extend Forwardable
include Callbacks
- METHODS: Array[verb]
+ METHODS: Array[Symbol]
USER_AGENT: String
- attr_reader verb: verb
- attr_reader uri: URI::HTTP | URI::HTTPS
+ attr_reader verb: Symbol
+ attr_reader uri: URI::Generic
attr_reader headers: Headers
attr_reader body: Body
attr_reader state: Symbol
attr_reader options: Options
attr_reader response: response?
attr_reader drain_error: StandardError?
- def initialize: (verb | String, generic_uri, ?options?) -> untyped
+ def initialize: (Symbol | String, generic_uri, ?options) -> untyped
def interests: () -> (:r | :w)
- def merge_headers: (_Each[[headers_key, headers_value]]) -> void
+ def merge_headers: (_Each[[String, headers_value]]) -> void
- def scheme: () -> ("http" | "https")
+ def scheme: () -> String
def response=: (response) -> void
def path: () -> String
@@ -47,20 +48,22 @@
class Body
def initialize: (Headers, Options) -> untyped
def each: () { (String) -> void } -> void
| () -> Enumerable[String]
+ def rewind: () -> void
def empty?: () -> bool
def bytesize: () -> Numeric
def stream: (Transcoder::_Encoder) -> bodyIO
def unbounded_body?: () -> bool
def chunked?: () -> bool
def chunk!: () -> void
def inspect: () -> String
end
class ProcIO
- include _Writer
- def initialize: (^(_ToS) -> void) -> untyped
+ def initialize: (^(String) -> void) -> untyped
+
+ def write: (String data) -> Integer
end
end
end