summaryrefslogtreecommitdiff
path: root/src/mongo/db/exec/projection_exec_agg.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/exec/projection_exec_agg.h')
-rw-r--r--src/mongo/db/exec/projection_exec_agg.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mongo/db/exec/projection_exec_agg.h b/src/mongo/db/exec/projection_exec_agg.h
index 12ab79c4b31..ea2317ee745 100644
--- a/src/mongo/db/exec/projection_exec_agg.h
+++ b/src/mongo/db/exec/projection_exec_agg.h
@@ -43,12 +43,6 @@ namespace mongo {
*/
class ProjectionExecAgg {
public:
- // Allows the caller to specify how the projection should handle nested arrays; that is, an
- // array whose immediate parent is itself an array. For example, in the case of sample document
- // {a: [1, 2, [3, 4], {b: [5, 6]}]} the array [3, 4] is a nested array. The array [5, 6] is not,
- // because there is an intervening object between it and its closest array ancestor.
- enum class ArrayRecursionPolicy { kRecurseNestedArrays, kDoNotRecurseNestedArrays };
-
// Allows the caller to indicate whether the projection should default to including or excluding
// the _id field in the event that the projection spec does not specify the desired behavior.
// For instance, given a projection {a: 1}, specifying 'kExcludeId' is equivalent to projecting
@@ -57,6 +51,12 @@ public:
// instance, {a: 1, _id: 0} will exclude _id for both 'kExcludeId' and 'kIncludeId'.
enum class DefaultIdPolicy { kIncludeId, kExcludeId };
+ // Allows the caller to specify how the projection should handle nested arrays; that is, an
+ // array whose immediate parent is itself an array. For example, in the case of sample document
+ // {a: [1, 2, [3, 4], {b: [5, 6]}]} the array [3, 4] is a nested array. The array [5, 6] is not,
+ // because there is an intervening object between it and its closest array ancestor.
+ enum class ArrayRecursionPolicy { kRecurseNestedArrays, kDoNotRecurseNestedArrays };
+
enum class ProjectionType { kInclusionProjection, kExclusionProjection };
static std::unique_ptr<ProjectionExecAgg> create(BSONObj projSpec,