module
CryBase::CouchBase::Services::KV::ResponseReader
Overview
Mixin that reads exactly one Response packet from the includer's
@socket. The includer is expected to own an IO-typed @socket.
Used together with RequestWriter and Bucket to compose
KV::Client. Stateless on its own.
class Peer
include KV::ResponseReader
def initialize(@socket : IO)
end
end
# `io` already contains a server response packet, positioned at start.
resp = Peer.new(io).read