Class: Async::IO::Protocol::Generic
- Inherits:
-
Object
- Object
- Async::IO::Protocol::Generic
- Defined in:
- lib/async/io/protocol/generic.rb
Instance Attribute Summary collapse
-
#stream ⇒ Object
readonly
Returns the value of attribute stream.
Instance Method Summary collapse
- #close ⇒ Object
- #closed? ⇒ Boolean
-
#initialize(stream) ⇒ Generic
constructor
A new instance of Generic.
Constructor Details
#initialize(stream) ⇒ Generic
Returns a new instance of Generic.
27 28 29 |
# File 'lib/async/io/protocol/generic.rb', line 27 def initialize(stream) @stream = stream end |
Instance Attribute Details
#stream ⇒ Object (readonly)
Returns the value of attribute stream.
39 40 41 |
# File 'lib/async/io/protocol/generic.rb', line 39 def stream @stream end |
Instance Method Details
#close ⇒ Object
35 36 37 |
# File 'lib/async/io/protocol/generic.rb', line 35 def close @stream.close end |
#closed? ⇒ Boolean
31 32 33 |
# File 'lib/async/io/protocol/generic.rb', line 31 def closed? @stream.closed? end |