Module: Luruju::DynamicMethod
- Included in:
- JudeApi::JudeBase
- Defined in:
- lib/luruju/enjoy_ruby.rb
Defined Under Namespace
Classes: IsNotMyRole
Instance Method Summary collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &b) ⇒ Object
8 9 10 11 12 13 |
# File 'lib/luruju/enjoy_ruby.rb', line 8 def method_missing method, *args, &b methods.select{|m|/^dyna_.*/ =~ m.to_s}.sort.each do |dyna_method| return send(dyna_method, method, *args, &b) rescue IsNotMyRole end super method, *args, &b end |