Class: Bouncer
- Inherits:
-
Object
- Object
- Bouncer
- Defined in:
- lib/melody_object/Mo_h_hc.rb
Instance Attribute Summary collapse
-
#chn ⇒ Object
Returns the value of attribute chn.
-
#del ⇒ Object
Returns the value of attribute del.
-
#done ⇒ Object
Returns the value of attribute done.
-
#inc ⇒ Object
Returns the value of attribute inc.
-
#leng ⇒ Object
Returns the value of attribute leng.
-
#running ⇒ Object
Returns the value of attribute running.
-
#sender ⇒ Object
Returns the value of attribute sender.
-
#turned_on ⇒ Object
Returns the value of attribute turned_on.
-
#val ⇒ Object
Returns the value of attribute val.
Instance Method Summary collapse
-
#initialize(packet = nil, chn = 0, leg = 4) ⇒ Bouncer
constructor
A new instance of Bouncer.
- #uf ⇒ Object
Constructor Details
#initialize(packet = nil, chn = 0, leg = 4) ⇒ Bouncer
Returns a new instance of Bouncer.
31 32 33 34 35 36 37 38 39 40 |
# File 'lib/melody_object/Mo_h_hc.rb', line 31 def initialize(packet=nil,chn=0,leg=4) @running=true @inc=0 @turned_on=false @val=packet @chn=chn leg=4 if leg.nil? @leng=leg #~ puts @leng end |
Instance Attribute Details
#chn ⇒ Object
Returns the value of attribute chn.
29 30 31 |
# File 'lib/melody_object/Mo_h_hc.rb', line 29 def chn @chn end |
#del ⇒ Object
Returns the value of attribute del.
27 28 29 |
# File 'lib/melody_object/Mo_h_hc.rb', line 27 def del @del end |
#done ⇒ Object
Returns the value of attribute done.
21 22 23 |
# File 'lib/melody_object/Mo_h_hc.rb', line 21 def done @done end |
#inc ⇒ Object
Returns the value of attribute inc.
25 26 27 |
# File 'lib/melody_object/Mo_h_hc.rb', line 25 def inc @inc end |
#leng ⇒ Object
Returns the value of attribute leng.
26 27 28 |
# File 'lib/melody_object/Mo_h_hc.rb', line 26 def leng @leng end |
#running ⇒ Object
Returns the value of attribute running.
23 24 25 |
# File 'lib/melody_object/Mo_h_hc.rb', line 23 def running @running end |
#sender ⇒ Object
Returns the value of attribute sender.
28 29 30 |
# File 'lib/melody_object/Mo_h_hc.rb', line 28 def sender @sender end |
#turned_on ⇒ Object
Returns the value of attribute turned_on.
24 25 26 |
# File 'lib/melody_object/Mo_h_hc.rb', line 24 def turned_on @turned_on end |
#val ⇒ Object
Returns the value of attribute val.
22 23 24 |
# File 'lib/melody_object/Mo_h_hc.rb', line 22 def val @val end |
Instance Method Details
#uf ⇒ Object
42 43 44 |
# File 'lib/melody_object/Mo_h_hc.rb', line 42 def uf Marshal::load(Marshal.dump(self)) end |