Class: TNETS::StreamParser
- Includes:
- Enumerable
- Defined in:
- lib/tnetstrings.rb
Instance Attribute Summary collapse
-
#io ⇒ Object
readonly
Returns the value of attribute io.
Instance Method Summary collapse
- #each(&blk) ⇒ Object
-
#initialize(io) ⇒ StreamParser
constructor
A new instance of StreamParser.
Methods included from Enumerable
#each_tnets, #stream_tnets, #to_tnets
Constructor Details
#initialize(io) ⇒ StreamParser
Returns a new instance of StreamParser.
16 17 18 |
# File 'lib/tnetstrings.rb', line 16 def initialize(io) @io = io end |
Instance Attribute Details
#io ⇒ Object (readonly)
Returns the value of attribute io.
15 16 17 |
# File 'lib/tnetstrings.rb', line 15 def io @io end |
Instance Method Details
#each(&blk) ⇒ Object
21 22 23 |
# File 'lib/tnetstrings.rb', line 21 def each(&blk) c_tnets_stream(io, &blk) end |