Module: Mongoid::Indexes::Validators::Options
Overview
Validates the options passed to the index macro.
Constant Summary collapse
- VALID_OPTIONS =
[ :background, :drop_dups, :name, :sparse, :unique, :max, :min ]
- VALID_TYPES =
[ 1, -1, "2d" ]
Instance Method Summary collapse
-
#validate(klass, spec, options) ⇒ Object
Validate the index specification.
Instance Method Details
#validate(klass, spec, options) ⇒ Object
Validate the index specification.
25 26 27 28 |
# File 'lib/mongoid/indexes/validators/options.rb', line 25 def validate(klass, spec, ) validate_spec(klass, spec, ) (klass, spec, ) end |