diff options
Diffstat (limited to 'src/mongo/db/pipeline/expression_context.h')
-rw-r--r-- | src/mongo/db/pipeline/expression_context.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mongo/db/pipeline/expression_context.h b/src/mongo/db/pipeline/expression_context.h index 9334cd4ecff..15a0d15ed48 100644 --- a/src/mongo/db/pipeline/expression_context.h +++ b/src/mongo/db/pipeline/expression_context.h @@ -290,6 +290,15 @@ public: }; /** + * Returns true if there are no namespaces in the query other than the namespace the query was + * issued against. eg if there is no $out, $lookup ect. If namespaces have not yet been resolved + * then it will also return false. + */ + bool noForeignNamespaces() const { + return _resolvedNamespaces.empty(); + } + + /** * Convenience call that returns true if the tailableMode indicates a tailable and awaitData * query. */ |