Sha256: ed76e6e3fba59fc22ff67d1c88f92d29286006c6a0dc7d6bd8b434e544ceaba1

Contents?: true

Size: 1.18 KB

Versions: 3

Compression:

Stored size: 1.18 KB

Contents

module HTTPX
  class Response::Body
    include _Reader
    include _ToS
    include _ToStr

    attr_reader encoding: Encoding | String
    attr_reader encodings: Array[Encoding | String]

    @response: Response
    @headers: Headers
    @options: Options
    @state: :idle | :memory | :buffer | :closed
    @window_size: Integer
    @length: Integer
    @buffer: StringIO | Tempfile | nil
    @reader: StringIO | Tempfile | nil
    @inflaters: Array[Transcoder::_Inflater]

    def initialize: (Response, Options) -> void

    def closed?: () -> bool

    def write:(String chunk) -> Integer?

    def filename: () -> String?

    def bytesize: () -> Integer

    def each: () { (String) -> void } -> void
            | () -> Enumerable[String]

    def empty?: () -> bool

    def copy_to: (String | File | _Writer destination) -> void

    def close: () -> void

    def rewind: () -> void

    private

    def initialize_inflaters: () -> void

    def self.initialize_inflater_by_encoding: (Encoding | String encoding, Response response, ?bytesize: Integer) -> Transcoder::GZIP::Inflater

    def transition: (Symbol nextstate) -> void

    def _with_same_buffer_pos: [A] () { () -> A } -> A
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
httpx-1.1.2 sig/response/body.rbs
httpx-1.1.1 sig/response/body.rbs
httpx-1.1.0 sig/response/body.rbs