Module: Rex::Services::LocalRelay::Stream
- Defined in:
- lib/rex/services/local_relay.rb
Overview
This module is used to extend streams such that they can be associated with a relay context and the other side of the stream.
Instance Attribute Summary collapse
-
#other_stream ⇒ Object
Returns the value of attribute other_stream.
-
#relay ⇒ Object
Returns the value of attribute relay.
Instance Method Summary collapse
-
#on_other_data(data) ⇒ Object
This method is called when the other side has data that has been read in.
Instance Attribute Details
#other_stream ⇒ Object
Returns the value of attribute other_stream.
40 41 42 |
# File 'lib/rex/services/local_relay.rb', line 40 def other_stream @other_stream end |
#relay ⇒ Object
Returns the value of attribute relay.
39 40 41 |
# File 'lib/rex/services/local_relay.rb', line 39 def relay @relay end |
Instance Method Details
#on_other_data(data) ⇒ Object
This method is called when the other side has data that has been read in.
31 32 33 34 35 36 37 |
# File 'lib/rex/services/local_relay.rb', line 31 def on_other_data(data) if relay.on_other_data_proc relay.on_other_data_proc.call(relay, self, data) else put(data) end end |