Class: FFWD::Channel::Sub
- Inherits:
-
Object
- Object
- FFWD::Channel::Sub
- Defined in:
- lib/ffwd/channel.rb
Instance Attribute Summary collapse
-
#block ⇒ Object
readonly
Returns the value of attribute block.
-
#channel ⇒ Object
readonly
Returns the value of attribute channel.
Instance Method Summary collapse
-
#initialize(channel, block) ⇒ Sub
constructor
A new instance of Sub.
- #unsubscribe ⇒ Object
Constructor Details
#initialize(channel, block) ⇒ Sub
Returns a new instance of Sub.
24 25 26 27 |
# File 'lib/ffwd/channel.rb', line 24 def initialize channel, block @channel = channel @block = block end |
Instance Attribute Details
#block ⇒ Object (readonly)
Returns the value of attribute block.
22 23 24 |
# File 'lib/ffwd/channel.rb', line 22 def block @block end |
#channel ⇒ Object (readonly)
Returns the value of attribute channel.
22 23 24 |
# File 'lib/ffwd/channel.rb', line 22 def channel @channel end |
Instance Method Details
#unsubscribe ⇒ Object
29 30 31 |
# File 'lib/ffwd/channel.rb', line 29 def unsubscribe @channel.unsubscribe self end |