Module | Mongoid::Relations::Embedded::Sort |
In: |
lib/mongoid/relations/embedded/sort.rb
|
This module handles embedded associations sorting Since mongodb doesn‘t have virtual collection for embedded docs yet (see jira.mongodb.org/browse/SERVER-142 for details) Sorting implemented in ruby This can be a performance killer on collections with many embedded documents
Sorts documents
@param [ Array<Documents> ] documents array of documents @param [ Mongoid::Relations::Metadata ] metadata association metadata