Method: Sunspot::FulltextField#initialize
- Defined in:
- lib/sunspot/field.rb
#initialize(name, options = {}) ⇒ FulltextField
Returns a new instance of FulltextField.
102 103 104 105 106 107 108 109 110 |
# File 'lib/sunspot/field.rb', line 102 def initialize(name, = {}) super(name, Type::TextType, ) @multiple = true if boost = .delete(:boost) @attributes[:boost] = boost end @default_boost = .delete(:default_boost) raise ArgumentError, "Unknown field option #{options.keys.first.inspect} provided for field #{name.inspect}" unless .empty? end |