summaryrefslogtreecommitdiff
path: root/src/mongo/db/exec
diff options
context:
space:
mode:
authorDavid Storch <david.storch@10gen.com>2015-04-14 14:53:19 -0400
committerDavid Storch <david.storch@10gen.com>2015-04-17 17:23:03 +1000
commitd03a9b6cbc6f5554738f4dd291809b73e3bb4c8a (patch)
tree2690d9df98f7ec3af073387468c5001c55cf2b76 /src/mongo/db/exec
parent7745af75e699fa94051000b801769e1a6310e898 (diff)
downloadmongo-d03a9b6cbc6f5554738f4dd291809b73e3bb4c8a.tar.gz
SERVER-17633 add const qualifiers to PlanStage and Explain interfaces
Diffstat (limited to 'src/mongo/db/exec')
-rw-r--r--src/mongo/db/exec/and_hash.cpp4
-rw-r--r--src/mongo/db/exec/and_hash.h4
-rw-r--r--src/mongo/db/exec/and_sorted.cpp4
-rw-r--r--src/mongo/db/exec/and_sorted.h4
-rw-r--r--src/mongo/db/exec/cached_plan.cpp4
-rw-r--r--src/mongo/db/exec/cached_plan.h4
-rw-r--r--src/mongo/db/exec/collection_scan.cpp4
-rw-r--r--src/mongo/db/exec/collection_scan.h4
-rw-r--r--src/mongo/db/exec/count.cpp4
-rw-r--r--src/mongo/db/exec/count.h4
-rw-r--r--src/mongo/db/exec/count_scan.cpp4
-rw-r--r--src/mongo/db/exec/count_scan.h4
-rw-r--r--src/mongo/db/exec/delete.cpp4
-rw-r--r--src/mongo/db/exec/delete.h4
-rw-r--r--src/mongo/db/exec/distinct_scan.cpp4
-rw-r--r--src/mongo/db/exec/distinct_scan.h4
-rw-r--r--src/mongo/db/exec/eof.cpp6
-rw-r--r--src/mongo/db/exec/eof.h4
-rw-r--r--src/mongo/db/exec/fetch.cpp4
-rw-r--r--src/mongo/db/exec/fetch.h4
-rw-r--r--src/mongo/db/exec/group.cpp4
-rw-r--r--src/mongo/db/exec/group.h4
-rw-r--r--src/mongo/db/exec/idhack.cpp4
-rw-r--r--src/mongo/db/exec/idhack.h4
-rw-r--r--src/mongo/db/exec/index_scan.cpp4
-rw-r--r--src/mongo/db/exec/index_scan.h4
-rw-r--r--src/mongo/db/exec/keep_mutations.cpp4
-rw-r--r--src/mongo/db/exec/keep_mutations.h4
-rw-r--r--src/mongo/db/exec/limit.cpp4
-rw-r--r--src/mongo/db/exec/limit.h4
-rw-r--r--src/mongo/db/exec/merge_sort.cpp4
-rw-r--r--src/mongo/db/exec/merge_sort.h4
-rw-r--r--src/mongo/db/exec/multi_iterator.h4
-rw-r--r--src/mongo/db/exec/multi_plan.cpp4
-rw-r--r--src/mongo/db/exec/multi_plan.h4
-rw-r--r--src/mongo/db/exec/near.cpp4
-rw-r--r--src/mongo/db/exec/near.h4
-rw-r--r--src/mongo/db/exec/oplogstart.h4
-rw-r--r--src/mongo/db/exec/or.cpp4
-rw-r--r--src/mongo/db/exec/or.h4
-rw-r--r--src/mongo/db/exec/pipeline_proxy.h4
-rw-r--r--src/mongo/db/exec/plan_stage.h4
-rw-r--r--src/mongo/db/exec/projection.cpp4
-rw-r--r--src/mongo/db/exec/projection.h4
-rw-r--r--src/mongo/db/exec/queued_data_stage.cpp4
-rw-r--r--src/mongo/db/exec/queued_data_stage.h4
-rw-r--r--src/mongo/db/exec/shard_filter.cpp4
-rw-r--r--src/mongo/db/exec/shard_filter.h5
-rw-r--r--src/mongo/db/exec/skip.cpp4
-rw-r--r--src/mongo/db/exec/skip.h4
-rw-r--r--src/mongo/db/exec/sort.cpp4
-rw-r--r--src/mongo/db/exec/sort.h4
-rw-r--r--src/mongo/db/exec/subplan.cpp4
-rw-r--r--src/mongo/db/exec/subplan.h4
-rw-r--r--src/mongo/db/exec/text.cpp4
-rw-r--r--src/mongo/db/exec/text.h4
-rw-r--r--src/mongo/db/exec/update.cpp4
-rw-r--r--src/mongo/db/exec/update.h4
58 files changed, 117 insertions, 118 deletions
diff --git a/src/mongo/db/exec/and_hash.cpp b/src/mongo/db/exec/and_hash.cpp
index 4a11db9862c..64bac7b3c66 100644
--- a/src/mongo/db/exec/and_hash.cpp
+++ b/src/mongo/db/exec/and_hash.cpp
@@ -543,11 +543,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* AndHashStage::getCommonStats() {
+ const CommonStats* AndHashStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* AndHashStage::getSpecificStats() {
+ const SpecificStats* AndHashStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/and_hash.h b/src/mongo/db/exec/and_hash.h
index 7a9eb3228f3..1fe60234c85 100644
--- a/src/mongo/db/exec/and_hash.h
+++ b/src/mongo/db/exec/and_hash.h
@@ -87,9 +87,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/and_sorted.cpp b/src/mongo/db/exec/and_sorted.cpp
index e0e0a664806..91036304f58 100644
--- a/src/mongo/db/exec/and_sorted.cpp
+++ b/src/mongo/db/exec/and_sorted.cpp
@@ -339,11 +339,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* AndSortedStage::getCommonStats() {
+ const CommonStats* AndSortedStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* AndSortedStage::getSpecificStats() {
+ const SpecificStats* AndSortedStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/and_sorted.h b/src/mongo/db/exec/and_sorted.h
index b6c3a9ed10e..dc57f80afcd 100644
--- a/src/mongo/db/exec/and_sorted.h
+++ b/src/mongo/db/exec/and_sorted.h
@@ -71,9 +71,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/cached_plan.cpp b/src/mongo/db/exec/cached_plan.cpp
index a8d2d1d592b..7e3fed36a98 100644
--- a/src/mongo/db/exec/cached_plan.cpp
+++ b/src/mongo/db/exec/cached_plan.cpp
@@ -348,11 +348,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* CachedPlanStage::getCommonStats() {
+ const CommonStats* CachedPlanStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* CachedPlanStage::getSpecificStats() {
+ const SpecificStats* CachedPlanStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/cached_plan.h b/src/mongo/db/exec/cached_plan.h
index c5d15fb7cac..ccc82d9cc7d 100644
--- a/src/mongo/db/exec/cached_plan.h
+++ b/src/mongo/db/exec/cached_plan.h
@@ -75,9 +75,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/collection_scan.cpp b/src/mongo/db/exec/collection_scan.cpp
index af7605c512b..7815ec85926 100644
--- a/src/mongo/db/exec/collection_scan.cpp
+++ b/src/mongo/db/exec/collection_scan.cpp
@@ -270,11 +270,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* CollectionScan::getCommonStats() {
+ const CommonStats* CollectionScan::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* CollectionScan::getSpecificStats() {
+ const SpecificStats* CollectionScan::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/collection_scan.h b/src/mongo/db/exec/collection_scan.h
index 375e4ad8fde..939b293b209 100644
--- a/src/mongo/db/exec/collection_scan.h
+++ b/src/mongo/db/exec/collection_scan.h
@@ -67,9 +67,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/count.cpp b/src/mongo/db/exec/count.cpp
index 512ae52a2e2..5fbcc28a40b 100644
--- a/src/mongo/db/exec/count.cpp
+++ b/src/mongo/db/exec/count.cpp
@@ -209,11 +209,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* CountStage::getCommonStats() {
+ const CommonStats* CountStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* CountStage::getSpecificStats() {
+ const SpecificStats* CountStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/count.h b/src/mongo/db/exec/count.h
index 4a2954ad140..70081984d23 100644
--- a/src/mongo/db/exec/count.h
+++ b/src/mongo/db/exec/count.h
@@ -98,9 +98,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/count_scan.cpp b/src/mongo/db/exec/count_scan.cpp
index 5ab657704f3..1a801c82566 100644
--- a/src/mongo/db/exec/count_scan.cpp
+++ b/src/mongo/db/exec/count_scan.cpp
@@ -168,11 +168,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* CountScan::getCommonStats() {
+ const CommonStats* CountScan::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* CountScan::getSpecificStats() {
+ const SpecificStats* CountScan::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/count_scan.h b/src/mongo/db/exec/count_scan.h
index e1b3966a22e..d04b2b89e8b 100644
--- a/src/mongo/db/exec/count_scan.h
+++ b/src/mongo/db/exec/count_scan.h
@@ -82,9 +82,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/delete.cpp b/src/mongo/db/exec/delete.cpp
index 678b5197acd..0a8cb0509da 100644
--- a/src/mongo/db/exec/delete.cpp
+++ b/src/mongo/db/exec/delete.cpp
@@ -296,11 +296,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* DeleteStage::getCommonStats() {
+ const CommonStats* DeleteStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* DeleteStage::getSpecificStats() {
+ const SpecificStats* DeleteStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/delete.h b/src/mongo/db/exec/delete.h
index cfd599750bf..c84d0e9bfd6 100644
--- a/src/mongo/db/exec/delete.h
+++ b/src/mongo/db/exec/delete.h
@@ -100,9 +100,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/distinct_scan.cpp b/src/mongo/db/exec/distinct_scan.cpp
index 9a38f7d675a..4185877064c 100644
--- a/src/mongo/db/exec/distinct_scan.cpp
+++ b/src/mongo/db/exec/distinct_scan.cpp
@@ -154,11 +154,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* DistinctScan::getCommonStats() {
+ const CommonStats* DistinctScan::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* DistinctScan::getSpecificStats() {
+ const SpecificStats* DistinctScan::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/distinct_scan.h b/src/mongo/db/exec/distinct_scan.h
index bfc18104cea..8d7f0a8a18b 100644
--- a/src/mongo/db/exec/distinct_scan.h
+++ b/src/mongo/db/exec/distinct_scan.h
@@ -92,9 +92,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/eof.cpp b/src/mongo/db/exec/eof.cpp
index 3b9b3528b2f..1766c9b7a3e 100644
--- a/src/mongo/db/exec/eof.cpp
+++ b/src/mongo/db/exec/eof.cpp
@@ -76,12 +76,12 @@ namespace mongo {
return new PlanStageStats(_commonStats, STAGE_EOF);
}
- const CommonStats* EOFStage::getCommonStats() {
+ const CommonStats* EOFStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* EOFStage::getSpecificStats() {
- return NULL;
+ const SpecificStats* EOFStage::getSpecificStats() const {
+ return nullptr;
}
} // namespace mongo
diff --git a/src/mongo/db/exec/eof.h b/src/mongo/db/exec/eof.h
index 7d83b4e2e96..247453d1d03 100644
--- a/src/mongo/db/exec/eof.h
+++ b/src/mongo/db/exec/eof.h
@@ -55,9 +55,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/fetch.cpp b/src/mongo/db/exec/fetch.cpp
index b98a04da01c..423ef2546c3 100644
--- a/src/mongo/db/exec/fetch.cpp
+++ b/src/mongo/db/exec/fetch.cpp
@@ -249,11 +249,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* FetchStage::getCommonStats() {
+ const CommonStats* FetchStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* FetchStage::getSpecificStats() {
+ const SpecificStats* FetchStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/fetch.h b/src/mongo/db/exec/fetch.h
index 05af024ef90..18fbeedb3db 100644
--- a/src/mongo/db/exec/fetch.h
+++ b/src/mongo/db/exec/fetch.h
@@ -68,9 +68,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/group.cpp b/src/mongo/db/exec/group.cpp
index 85e7d613cc2..d5d3688d4c5 100644
--- a/src/mongo/db/exec/group.cpp
+++ b/src/mongo/db/exec/group.cpp
@@ -292,11 +292,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* GroupStage::getCommonStats() {
+ const CommonStats* GroupStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* GroupStage::getSpecificStats() {
+ const SpecificStats* GroupStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/group.h b/src/mongo/db/exec/group.h
index 2374fc7b2b0..dcf96570cbe 100644
--- a/src/mongo/db/exec/group.h
+++ b/src/mongo/db/exec/group.h
@@ -100,9 +100,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/idhack.cpp b/src/mongo/db/exec/idhack.cpp
index 98aeb7162ff..26de70dc7aa 100644
--- a/src/mongo/db/exec/idhack.cpp
+++ b/src/mongo/db/exec/idhack.cpp
@@ -240,11 +240,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* IDHackStage::getCommonStats() {
+ const CommonStats* IDHackStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* IDHackStage::getSpecificStats() {
+ const SpecificStats* IDHackStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/idhack.h b/src/mongo/db/exec/idhack.h
index 800cd8e4675..d1f1020342d 100644
--- a/src/mongo/db/exec/idhack.h
+++ b/src/mongo/db/exec/idhack.h
@@ -68,9 +68,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/index_scan.cpp b/src/mongo/db/exec/index_scan.cpp
index e8f59c07496..3cf0ed093cb 100644
--- a/src/mongo/db/exec/index_scan.cpp
+++ b/src/mongo/db/exec/index_scan.cpp
@@ -308,11 +308,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* IndexScan::getCommonStats() {
+ const CommonStats* IndexScan::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* IndexScan::getSpecificStats() {
+ const SpecificStats* IndexScan::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/index_scan.h b/src/mongo/db/exec/index_scan.h
index a2cfd4bad45..0a3c1436103 100644
--- a/src/mongo/db/exec/index_scan.h
+++ b/src/mongo/db/exec/index_scan.h
@@ -114,9 +114,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/keep_mutations.cpp b/src/mongo/db/exec/keep_mutations.cpp
index a6db0eb0efd..a58c979f02a 100644
--- a/src/mongo/db/exec/keep_mutations.cpp
+++ b/src/mongo/db/exec/keep_mutations.cpp
@@ -148,11 +148,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* KeepMutationsStage::getCommonStats() {
+ const CommonStats* KeepMutationsStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* KeepMutationsStage::getSpecificStats() {
+ const SpecificStats* KeepMutationsStage::getSpecificStats() const {
return NULL;
}
diff --git a/src/mongo/db/exec/keep_mutations.h b/src/mongo/db/exec/keep_mutations.h
index 004106ba315..a4c594a1f33 100644
--- a/src/mongo/db/exec/keep_mutations.h
+++ b/src/mongo/db/exec/keep_mutations.h
@@ -63,9 +63,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/limit.cpp b/src/mongo/db/exec/limit.cpp
index 6aa83f083bc..87527e36970 100644
--- a/src/mongo/db/exec/limit.cpp
+++ b/src/mongo/db/exec/limit.cpp
@@ -121,11 +121,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* LimitStage::getCommonStats() {
+ const CommonStats* LimitStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* LimitStage::getSpecificStats() {
+ const SpecificStats* LimitStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/limit.h b/src/mongo/db/exec/limit.h
index 489eea2e589..484df742439 100644
--- a/src/mongo/db/exec/limit.h
+++ b/src/mongo/db/exec/limit.h
@@ -61,9 +61,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/merge_sort.cpp b/src/mongo/db/exec/merge_sort.cpp
index ab6e9f547e2..8fdb3ae96eb 100644
--- a/src/mongo/db/exec/merge_sort.cpp
+++ b/src/mongo/db/exec/merge_sort.cpp
@@ -278,11 +278,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* MergeSortStage::getCommonStats() {
+ const CommonStats* MergeSortStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* MergeSortStage::getSpecificStats() {
+ const SpecificStats* MergeSortStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/merge_sort.h b/src/mongo/db/exec/merge_sort.h
index 353fbaa14ec..e8e216e5fe3 100644
--- a/src/mongo/db/exec/merge_sort.h
+++ b/src/mongo/db/exec/merge_sort.h
@@ -75,9 +75,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/multi_iterator.h b/src/mongo/db/exec/multi_iterator.h
index 453ffdfdce6..0fd88283aa7 100644
--- a/src/mongo/db/exec/multi_iterator.h
+++ b/src/mongo/db/exec/multi_iterator.h
@@ -69,8 +69,8 @@ namespace mongo {
//
virtual PlanStageStats* getStats() { return NULL; }
- virtual CommonStats* getCommonStats() { return NULL; }
- virtual SpecificStats* getSpecificStats() { return NULL; }
+ virtual CommonStats* getCommonStats() const { return NULL; }
+ virtual SpecificStats* getSpecificStats() const { return NULL; }
virtual std::vector<PlanStage*> getChildren() const;
diff --git a/src/mongo/db/exec/multi_plan.cpp b/src/mongo/db/exec/multi_plan.cpp
index 3ad74d752ce..23e24a57d2c 100644
--- a/src/mongo/db/exec/multi_plan.cpp
+++ b/src/mongo/db/exec/multi_plan.cpp
@@ -508,11 +508,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* MultiPlanStage::getCommonStats() {
+ const CommonStats* MultiPlanStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* MultiPlanStage::getSpecificStats() {
+ const SpecificStats* MultiPlanStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/multi_plan.h b/src/mongo/db/exec/multi_plan.h
index 43596aea247..d820324dfe8 100644
--- a/src/mongo/db/exec/multi_plan.h
+++ b/src/mongo/db/exec/multi_plan.h
@@ -81,9 +81,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
/**
* Takes ownership of QuerySolution and PlanStage. not of WorkingSet
diff --git a/src/mongo/db/exec/near.cpp b/src/mongo/db/exec/near.cpp
index cb1abf498a5..c3e5654b17b 100644
--- a/src/mongo/db/exec/near.cpp
+++ b/src/mongo/db/exec/near.cpp
@@ -386,11 +386,11 @@ namespace mongo {
return _stats->stageType;
}
- const CommonStats* NearStage::getCommonStats() {
+ const CommonStats* NearStage::getCommonStats() const {
return &_stats->common;
}
- const SpecificStats* NearStage::getSpecificStats() {
+ const SpecificStats* NearStage::getSpecificStats() const {
return _stats->specific.get();
}
diff --git a/src/mongo/db/exec/near.h b/src/mongo/db/exec/near.h
index d7d27a78331..a3db2c2b126 100644
--- a/src/mongo/db/exec/near.h
+++ b/src/mongo/db/exec/near.h
@@ -92,8 +92,8 @@ namespace mongo {
virtual StageType stageType() const;
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
- virtual const SpecificStats* getSpecificStats();
+ virtual const CommonStats* getCommonStats() const;
+ virtual const SpecificStats* getSpecificStats() const;
protected:
diff --git a/src/mongo/db/exec/oplogstart.h b/src/mongo/db/exec/oplogstart.h
index 78505a2a54c..5a52dc37489 100644
--- a/src/mongo/db/exec/oplogstart.h
+++ b/src/mongo/db/exec/oplogstart.h
@@ -83,9 +83,9 @@ namespace mongo {
virtual PlanStageStats* getStats() { return NULL; }
- virtual const CommonStats* getCommonStats() { return NULL; }
+ virtual const CommonStats* getCommonStats() const { return NULL; }
- virtual const SpecificStats* getSpecificStats() { return NULL; }
+ virtual const SpecificStats* getSpecificStats() const { return NULL; }
virtual StageType stageType() const { return STAGE_OPLOG_START; }
diff --git a/src/mongo/db/exec/or.cpp b/src/mongo/db/exec/or.cpp
index 8b3dd286b1b..ee57187c2a2 100644
--- a/src/mongo/db/exec/or.cpp
+++ b/src/mongo/db/exec/or.cpp
@@ -201,11 +201,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* OrStage::getCommonStats() {
+ const CommonStats* OrStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* OrStage::getSpecificStats() {
+ const SpecificStats* OrStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/or.h b/src/mongo/db/exec/or.h
index c0f92a01327..3ea2d55a466 100644
--- a/src/mongo/db/exec/or.h
+++ b/src/mongo/db/exec/or.h
@@ -64,9 +64,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/pipeline_proxy.h b/src/mongo/db/exec/pipeline_proxy.h
index 59a4d61d197..23ac96ca365 100644
--- a/src/mongo/db/exec/pipeline_proxy.h
+++ b/src/mongo/db/exec/pipeline_proxy.h
@@ -79,8 +79,8 @@ namespace mongo {
//
virtual PlanStageStats* getStats() { return NULL; }
- virtual CommonStats* getCommonStats() { return NULL; }
- virtual SpecificStats* getSpecificStats() { return NULL; }
+ virtual CommonStats* getCommonStats() const { return NULL; }
+ virtual SpecificStats* getSpecificStats() const { return NULL; }
// Not used.
virtual std::vector<PlanStage*> getChildren() const;
diff --git a/src/mongo/db/exec/plan_stage.h b/src/mongo/db/exec/plan_stage.h
index 98d1d80698d..07536817ca6 100644
--- a/src/mongo/db/exec/plan_stage.h
+++ b/src/mongo/db/exec/plan_stage.h
@@ -271,7 +271,7 @@ namespace mongo {
* It must not exist past the stage. If you need the stats to outlive the stage,
* use the getStats(...) method above.
*/
- virtual const CommonStats* getCommonStats() = 0;
+ virtual const CommonStats* getCommonStats() const = 0;
/**
* Get stats specific to this stage. Some stages may not have specific stats, in which
@@ -281,7 +281,7 @@ namespace mongo {
* It must not exist past the stage. If you need the stats to outlive the stage,
* use the getStats(...) method above.
*/
- virtual const SpecificStats* getSpecificStats() = 0;
+ virtual const SpecificStats* getSpecificStats() const = 0;
};
diff --git a/src/mongo/db/exec/projection.cpp b/src/mongo/db/exec/projection.cpp
index e907a5eca7a..25616bfb197 100644
--- a/src/mongo/db/exec/projection.cpp
+++ b/src/mongo/db/exec/projection.cpp
@@ -285,11 +285,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* ProjectionStage::getCommonStats() {
+ const CommonStats* ProjectionStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* ProjectionStage::getSpecificStats() {
+ const SpecificStats* ProjectionStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/projection.h b/src/mongo/db/exec/projection.h
index 7724216b00e..6878861a997 100644
--- a/src/mongo/db/exec/projection.h
+++ b/src/mongo/db/exec/projection.h
@@ -95,9 +95,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
typedef unordered_set<StringData, StringData::Hasher> FieldSet;
diff --git a/src/mongo/db/exec/queued_data_stage.cpp b/src/mongo/db/exec/queued_data_stage.cpp
index 1e40b87d21a..b353cb6026d 100644
--- a/src/mongo/db/exec/queued_data_stage.cpp
+++ b/src/mongo/db/exec/queued_data_stage.cpp
@@ -89,9 +89,9 @@ namespace mongo {
return ret.release();
}
- const CommonStats* QueuedDataStage::getCommonStats() { return &_commonStats; }
+ const CommonStats* QueuedDataStage::getCommonStats() const { return &_commonStats; }
- const SpecificStats* QueuedDataStage::getSpecificStats() { return &_specificStats; }
+ const SpecificStats* QueuedDataStage::getSpecificStats() const { return &_specificStats; }
void QueuedDataStage::pushBack(const PlanStage::StageState state) {
invariant(PlanStage::ADVANCED != state);
diff --git a/src/mongo/db/exec/queued_data_stage.h b/src/mongo/db/exec/queued_data_stage.h
index b17566f1b1e..5d7a7b2b159 100644
--- a/src/mongo/db/exec/queued_data_stage.h
+++ b/src/mongo/db/exec/queued_data_stage.h
@@ -71,9 +71,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
/**
* Add a result to the back of the queue.
diff --git a/src/mongo/db/exec/shard_filter.cpp b/src/mongo/db/exec/shard_filter.cpp
index c1aa49df04e..26f546ec836 100644
--- a/src/mongo/db/exec/shard_filter.cpp
+++ b/src/mongo/db/exec/shard_filter.cpp
@@ -156,11 +156,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* ShardFilterStage::getCommonStats() {
+ const CommonStats* ShardFilterStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* ShardFilterStage::getSpecificStats() {
+ const SpecificStats* ShardFilterStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/shard_filter.h b/src/mongo/db/exec/shard_filter.h
index 16cc21d7392..f0b04ae9d4a 100644
--- a/src/mongo/db/exec/shard_filter.h
+++ b/src/mongo/db/exec/shard_filter.h
@@ -90,9 +90,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
@@ -110,4 +110,3 @@ namespace mongo {
};
} // namespace mongo
-
diff --git a/src/mongo/db/exec/skip.cpp b/src/mongo/db/exec/skip.cpp
index a0026d2b829..1a8f0ab5d57 100644
--- a/src/mongo/db/exec/skip.cpp
+++ b/src/mongo/db/exec/skip.cpp
@@ -124,11 +124,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* SkipStage::getCommonStats() {
+ const CommonStats* SkipStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* SkipStage::getSpecificStats() {
+ const SpecificStats* SkipStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/skip.h b/src/mongo/db/exec/skip.h
index b61f23a9c7f..ff3982a415c 100644
--- a/src/mongo/db/exec/skip.h
+++ b/src/mongo/db/exec/skip.h
@@ -60,9 +60,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/sort.cpp b/src/mongo/db/exec/sort.cpp
index da8c0bb57e5..6af1a48e319 100644
--- a/src/mongo/db/exec/sort.cpp
+++ b/src/mongo/db/exec/sort.cpp
@@ -483,11 +483,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* SortStage::getCommonStats() {
+ const CommonStats* SortStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* SortStage::getSpecificStats() {
+ const SpecificStats* SortStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/sort.h b/src/mongo/db/exec/sort.h
index 5211747c2ef..2255a5ce82c 100644
--- a/src/mongo/db/exec/sort.h
+++ b/src/mongo/db/exec/sort.h
@@ -161,9 +161,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/subplan.cpp b/src/mongo/db/exec/subplan.cpp
index 88cb23e5642..364c429429d 100644
--- a/src/mongo/db/exec/subplan.cpp
+++ b/src/mongo/db/exec/subplan.cpp
@@ -546,11 +546,11 @@ namespace mongo {
return NULL != _branchResults[i]->cachedSolution.get();
}
- const CommonStats* SubplanStage::getCommonStats() {
+ const CommonStats* SubplanStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* SubplanStage::getSpecificStats() {
+ const SpecificStats* SubplanStage::getSpecificStats() const {
return NULL;
}
diff --git a/src/mongo/db/exec/subplan.h b/src/mongo/db/exec/subplan.h
index 190da7988f9..8de399a4983 100644
--- a/src/mongo/db/exec/subplan.h
+++ b/src/mongo/db/exec/subplan.h
@@ -87,9 +87,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/text.cpp b/src/mongo/db/exec/text.cpp
index 67596b62157..b049c17b9ff 100644
--- a/src/mongo/db/exec/text.cpp
+++ b/src/mongo/db/exec/text.cpp
@@ -185,11 +185,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* TextStage::getCommonStats() {
+ const CommonStats* TextStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* TextStage::getSpecificStats() {
+ const SpecificStats* TextStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/text.h b/src/mongo/db/exec/text.h
index 6a5d01a818b..4a7364e052d 100644
--- a/src/mongo/db/exec/text.h
+++ b/src/mongo/db/exec/text.h
@@ -118,9 +118,9 @@ namespace mongo {
PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;
diff --git a/src/mongo/db/exec/update.cpp b/src/mongo/db/exec/update.cpp
index 54ae2c68b2d..0430202a241 100644
--- a/src/mongo/db/exec/update.cpp
+++ b/src/mongo/db/exec/update.cpp
@@ -1064,11 +1064,11 @@ namespace mongo {
return ret.release();
}
- const CommonStats* UpdateStage::getCommonStats() {
+ const CommonStats* UpdateStage::getCommonStats() const {
return &_commonStats;
}
- const SpecificStats* UpdateStage::getSpecificStats() {
+ const SpecificStats* UpdateStage::getSpecificStats() const {
return &_specificStats;
}
diff --git a/src/mongo/db/exec/update.h b/src/mongo/db/exec/update.h
index c1dbe9a185f..c1a9372eae9 100644
--- a/src/mongo/db/exec/update.h
+++ b/src/mongo/db/exec/update.h
@@ -100,9 +100,9 @@ namespace mongo {
virtual PlanStageStats* getStats();
- virtual const CommonStats* getCommonStats();
+ virtual const CommonStats* getCommonStats() const;
- virtual const SpecificStats* getSpecificStats();
+ virtual const SpecificStats* getSpecificStats() const;
static const char* kStageType;