Class: FilterForm::InputOptionsBuilder
- Inherits:
-
Object
- Object
- FilterForm::InputOptionsBuilder
- Defined in:
- lib/filter_form/input_options_builder.rb
Instance Attribute Summary collapse
-
#attribute_name ⇒ Object
Returns the value of attribute attribute_name.
-
#custom_predicate ⇒ Object
Returns the value of attribute custom_predicate.
-
#custom_type ⇒ Object
Returns the value of attribute custom_type.
-
#object ⇒ Object
Returns the value of attribute object.
Instance Method Summary collapse
- #build(options = {}) ⇒ Object
-
#initialize(options) ⇒ InputOptionsBuilder
constructor
A new instance of InputOptionsBuilder.
Constructor Details
#initialize(options) ⇒ InputOptionsBuilder
Returns a new instance of InputOptionsBuilder.
18 19 20 21 22 23 |
# File 'lib/filter_form/input_options_builder.rb', line 18 def initialize() @object = [:object] @custom_predicate = [:custom_predicate] @custom_type = [:custom_type] self.attribute_name = [:attribute_name] end |
Instance Attribute Details
#attribute_name ⇒ Object
Returns the value of attribute attribute_name.
16 17 18 |
# File 'lib/filter_form/input_options_builder.rb', line 16 def attribute_name @attribute_name end |
#custom_predicate ⇒ Object
Returns the value of attribute custom_predicate.
15 16 17 |
# File 'lib/filter_form/input_options_builder.rb', line 15 def custom_predicate @custom_predicate end |
#custom_type ⇒ Object
Returns the value of attribute custom_type.
15 16 17 |
# File 'lib/filter_form/input_options_builder.rb', line 15 def custom_type @custom_type end |
#object ⇒ Object
Returns the value of attribute object.
15 16 17 |
# File 'lib/filter_form/input_options_builder.rb', line 15 def object @object end |
Instance Method Details
#build(options = {}) ⇒ Object
26 27 28 |
# File 'lib/filter_form/input_options_builder.rb', line 26 def build( = {}) .new(attribute_name: attribute_name, object: object, custom_predicate: custom_predicate, options: ). end |