Class: Apia::DSLs::LookupArgumentSet
- Inherits:
-
ArgumentSet
- Object
- Apia::DSL
- ArgumentSet
- Apia::DSLs::LookupArgumentSet
- Defined in:
- lib/apia/dsls/lookup_argument_set.rb
Instance Method Summary collapse
Methods inherited from ArgumentSet
Methods inherited from Apia::DSL
#description, #initialize, #name, #no_schema
Constructor Details
This class inherits a constructor from Apia::DSL
Instance Method Details
#potential_error(klass, &block) ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/apia/dsls/lookup_argument_set.rb', line 9 def potential_error(klass, &block) if block_given? && klass.is_a?(String) id = "#{@definition.id}/#{Helpers.camelize(klass)}" klass = Apia::Error.create(id, &block) end @definition.potential_errors << klass end |
#resolver(&block) ⇒ Object
18 19 20 |
# File 'lib/apia/dsls/lookup_argument_set.rb', line 18 def resolver(&block) @definition.resolver = block end |