class Mongo::Operation::CollectionsInfo
A MongoDB operation to get info on all collections in a given database.
@api private
@since 2.0.0
Public Instance Methods
execute(server)
click to toggle source
Execute the operation.
@example
operation.execute(server)
@param [ Mongo::Server
] server The server to send the operation to.
@return [ Mongo::Operation::CollectionsInfo::Result
,
Mongo::Operation::ListCollections::Result ] The operation result.
@since 2.0.0
Calls superclass method
Mongo::Operation::Executable#execute
# File lib/mongo/operation/collections_info.rb, line 42 def execute(server) if server.features.list_collections_enabled? return Operation::ListCollections.new(spec).execute(server) end super end
Private Instance Methods
message(server)
click to toggle source
# File lib/mongo/operation/collections_info.rb, line 56 def message(server) Protocol::Query.new(db_name, Database::NAMESPACES, command(server), options(server)) end
selector(server)
click to toggle source
# File lib/mongo/operation/collections_info.rb, line 52 def selector(server) {} end