class Mongo::Operation::CollectionsInfo::Result
Defines custom behavior of results when query the system.namespaces collection.
@since 2.1.0 @api semiprivate
Public Class Methods
new(replies, connection_description, database_name)
click to toggle source
Initialize a new result.
@param [ Array<Protocol::Message> | nil ] replies The wire protocol replies, if any. @param [ Server::Description
] connection_description
Server description of the server that performed the operation that this result is for.
@param [ String ] database_name The name of the database that the
query was sent to.
@api private
Calls superclass method
Mongo::Operation::Result::new
# File lib/mongo/operation/collections_info/result.rb, line 39 def initialize(replies, connection_description, database_name) super(replies, connection_description) @database_name = database_name end
Public Instance Methods
namespace()
click to toggle source
Get the namespace for the cursor.
@example Get the namespace.
result.namespace
@return [ String ] The namespace.
@since 2.1.0 @api private
# File lib/mongo/operation/collections_info/result.rb, line 53 def namespace "#{@database_name}.#{Database::NAMESPACES}" end