Class: Mongo::Operation::CollectionsInfo::Result
- Defined in:
- lib/mongo/operation/collections_info/result.rb
Overview
Defines custom behavior of results when query the system.namespaces collection.
Constant Summary
Constants inherited from Result
Result::CURSOR, Result::CURSOR_ID, Result::FIRST_BATCH, Result::N, Result::NAMESPACE, Result::NEXT_BATCH, Result::OK, Result::RESULT
Instance Attribute Summary
Attributes inherited from Result
#connection, #connection_description, #connection_global_id, #context, #replies
Instance Method Summary collapse
-
#initialize(replies, connection_description, connection_global_id, database_name) ⇒ Result
constructor
private
Initialize a new result.
-
#namespace ⇒ String
private
Get the namespace for the cursor.
Methods inherited from Result
#acknowledged?, #cluster_time, #cursor_id, #documents, #each, #error, #has_cursor_id?, #inspect, #labels, #ok?, #operation_time, #reply, #returned_count, #snapshot_timestamp, #successful?, #topology_version, #validate!, #write_concern_error?, #written_count
Constructor Details
#initialize(replies, connection_description, connection_global_id, database_name) ⇒ Result
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Initialize a new result.
42 43 44 45 |
# File 'lib/mongo/operation/collections_info/result.rb', line 42 def initialize(replies, connection_description, connection_global_id, database_name) super(replies, connection_description, connection_global_id) @database_name = database_name end |
Instance Method Details
#namespace ⇒ String
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Get the namespace for the cursor.
56 57 58 |
# File 'lib/mongo/operation/collections_info/result.rb', line 56 def namespace "#{@database_name}.#{Database::NAMESPACES}" end |