Class: Support::QueryStruct
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- Support::QueryStruct
- Defined in:
- lib/support/query_struct.rb
Instance Method Summary collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *arguments, &block) ⇒ Object
5 6 7 8 |
# File 'lib/support/query_struct.rb', line 5 def method_missing(name, *arguments, &block) return super unless name.to_s =~ /^(?<name>.+)\?$/ !!super(Regexp.last_match(:name).to_sym, *arguments, &block) end |