Class: Admino::Query::Configuration::SearchField
- Inherits:
-
Object
- Object
- Admino::Query::Configuration::SearchField
- Defined in:
- lib/admino/query/configuration.rb
Instance Attribute Summary collapse
-
#coerce_to ⇒ Object
readonly
Returns the value of attribute coerce_to.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(name, options = {}) ⇒ SearchField
constructor
A new instance of SearchField.
Constructor Details
#initialize(name, options = {}) ⇒ SearchField
Returns a new instance of SearchField.
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/admino/query/configuration.rb', line 8 def initialize(name, = {}) .symbolize_keys! .assert_valid_keys(:coerce) @name = name.to_sym if coerce_to = [:coerce] @coerce_to = coerce_to.to_sym end end |
Instance Attribute Details
#coerce_to ⇒ Object (readonly)
Returns the value of attribute coerce_to.
6 7 8 |
# File 'lib/admino/query/configuration.rb', line 6 def coerce_to @coerce_to end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
5 6 7 |
# File 'lib/admino/query/configuration.rb', line 5 def name @name end |