Method: Contracts::MethodHandler#handle
- Defined in:
- lib/contracts/method_handler.rb
#handle ⇒ Object
Handles method addition
29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/contracts/method_handler.rb', line 29 def handle return unless engine? return if decorators.empty? validate_decorators! validate_pattern_matching! engine.add_method_decorator(method_type, method_name, decorator) mark_pattern_matching_decorators method_reference.make_alias(target) redefine_method end |