Module: OpenC3::Structure::MethodMissing
- Defined in:
- lib/openc3/packets/structure.rb
Instance Method Summary collapse
-
#method_missing(name, value = nil) ⇒ Object
Method missing provides reading/writing item values as if they were methods to the class.
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, value = nil) ⇒ Object
Method missing provides reading/writing item values as if they were methods to the class
575 576 577 578 579 580 581 582 |
# File 'lib/openc3/packets/structure.rb', line 575 def method_missing(name, value = nil) if value # Strip off the equals sign before looking up the item return write(name.to_s[0..-2], value) else return read(name.to_s) end end |