Module: Avro::Builder::DslOptions::ClassMethods
- Defined in:
- lib/avro/builder/dsl_options.rb
Instance Method Summary collapse
-
#dsl_option(name, &block) ⇒ Object
A DSL option is only settable as an option, not as method in a block.
- #dsl_option_names ⇒ Object
Instance Method Details
#dsl_option(name, &block) ⇒ Object
A DSL option is only settable as an option, not as method in a block.
23 24 25 26 27 |
# File 'lib/avro/builder/dsl_options.rb', line 23 def dsl_option(name, &block) add_option_name(name) define_private_writer(name) define_reader(name, &block) end |
#dsl_option_names ⇒ Object
29 30 31 32 33 34 35 36 |
# File 'lib/avro/builder/dsl_options.rb', line 29 def dsl_option_names @dsl_option_names ||= if superclass.respond_to?(:dsl_option_names) superclass.dsl_option_names.dup else Set.new end end |