Gets the entity body returned by the remote HTTP server.
If a block is given, the body is passed to the block, and the body is provided in fragments, as it is read in from the socket.
If dest
argument is given, response is read into that variable, with dest#<<
method (it could be String
or IO
, or any other object responding to <<
).
Calling this method a second or subsequent time for the same HTTPResponse
object will return the value already read.
http.request_get('/index.html') {|res| puts res.read_body } http.request_get('/index.html') {|res| p res.read_body.object_id # 538149362 p res.read_body.object_id # 538149362 } # using iterator http.request_get('/index.html') {|res| res.read_body do |segment| print segment end }
Similar to inspect, but respects the current level of indentation given by the pretty print object.
Convert this node into a graphviz dot graph string.
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def begin_keyword
: () -> String
?
def end_keyword
: () -> String
?
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]
def deconstruct_keys
: (keys: Array) -> Hash[Symbol, nil | Node
| Array | String
| Token
| Array | Location]