summaryrefslogtreecommitdiff
path: root/src/mongo/db/namespace_string.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/namespace_string.h')
-rw-r--r--src/mongo/db/namespace_string.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mongo/db/namespace_string.h b/src/mongo/db/namespace_string.h
index deaf6ba2111..f49054c57ef 100644
--- a/src/mongo/db/namespace_string.h
+++ b/src/mongo/db/namespace_string.h
@@ -96,6 +96,12 @@ public:
NamespaceString(StringData dbName, StringData collectionName);
/**
+ * Constructs the namespace '<dbName>.$cmd.aggregate', which we use as the namespace for
+ * aggregation commands with the format {aggregate: 1}.
+ */
+ static NamespaceString makeCollectionlessAggregateNSS(StringData dbName);
+
+ /**
* Constructs a NamespaceString representing a listCollections namespace. The format for this
* namespace is "<dbName>.$cmd.listCollections".
*/
@@ -213,6 +219,7 @@ public:
return coll().startsWith("$cmd."_sd);
}
+ bool isCollectionlessAggregateNS() const;
bool isListCollectionsCursorNS() const;
bool isListIndexesCursorNS() const;