Skip to content

Instantly share code, notes, and snippets.

@mana8626
Created January 4, 2012 08:24
Show Gist options
  • Save mana8626/1559086 to your computer and use it in GitHub Desktop.
Save mana8626/1559086 to your computer and use it in GitHub Desktop.
method missing実装してみたった!
class Ms
def method_missing name, *args, &blk
case name.to_s
when /^find_(.*)$/
puts $1
else
super
end
end
end
ms = Ms.new
ms.aaa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment