Sha256: 50b8663ff2681ca778ea63f8096efdb46a424cbfac1599a6461916b8c2322391
Contents?: true
Size: 481 Bytes
Versions: 15
Compression:
Stored size: 481 Bytes
Contents
module Faye class WebSocket class HybiParser class StreamReader def initialize @queue = [] end def read(length) read_bytes(length) end def put(bytes) return unless bytes and bytes.size > 0 @queue.concat(bytes) end private def read_bytes(length) return nil if length > @queue.size @queue.shift(length) end end end end end
Version data entries
15 entries across 15 versions & 2 rubygems