Module: Taro::Rails::DSL
- Defined in:
- lib/taro/rails/dsl.rb
Instance Method Summary collapse
- #api(summary) ⇒ Object
- #common_return(nesting = nil) ⇒ Object
- #method_added(method_name) ⇒ Object
- #param(param_name) ⇒ Object
- #returns(nesting = nil) ⇒ Object
Instance Method Details
#api(summary) ⇒ Object
2 3 4 |
# File 'lib/taro/rails/dsl.rb', line 2 def api(summary, **) Taro::Rails.buffered_declaration(self).add_info(summary, **) end |
#common_return(nesting = nil) ⇒ Object
21 22 23 24 |
# File 'lib/taro/rails/dsl.rb', line 21 def common_return(nesting = nil, **) defined_at = caller_locations(1..1)[0] Taro::CommonReturns.define(self, nesting, defined_at:, **) end |
#method_added(method_name) ⇒ Object
16 17 18 19 |
# File 'lib/taro/rails/dsl.rb', line 16 def method_added(method_name) Taro::Rails.apply_buffered_declaration(self, method_name) super end |
#param(param_name) ⇒ Object
6 7 8 9 |
# File 'lib/taro/rails/dsl.rb', line 6 def param(param_name, **) defined_at = caller_locations(1..1)[0] Taro::Rails.buffered_declaration(self).add_param(param_name, defined_at:, **) end |
#returns(nesting = nil) ⇒ Object
11 12 13 14 |
# File 'lib/taro/rails/dsl.rb', line 11 def returns(nesting = nil, **) defined_at = caller_locations(1..1)[0] Taro::Rails.buffered_declaration(self).add_return(nesting, defined_at:, **) end |