class Mongo::Operation::Read::Query

A MongoDB query operation.

@example Create the query operation.

Read::Query.new({
  :selector => { :foo => 1 },
  :db_name => 'test-db',
  :coll_name => 'test-coll',
  :options => { :limit => 2 }
})

Initialization:

param [ Hash ] spec The specifications for the query.

option spec :selector [ Hash ] The query selector.
option spec :db_name [ String ] The name of the database on which
  the query should be run.
option spec :coll_name [ String ] The name of the collection on which
  the query should be run.
option spec :options [ Hash ] Options for the query.

@since 2.0.0

Private Instance Methods

query_coll() click to toggle source
# File lib/mongo/operation/read/query.rb, line 49
def query_coll
  coll_name
end