diff options
author | unknown <Administrator@.(none)> | 2008-11-16 21:00:22 -0500 |
---|---|---|
committer | unknown <Administrator@.(none)> | 2008-11-16 21:00:22 -0500 |
commit | 3e53cfe1d7f31ad7fbae481d380110c9a041129c (patch) | |
tree | bbba86a63e76e536d6102412a33b52dddad6137e | |
parent | e227ff9bacc1beeb1a026b61c104e92d4cc2872b (diff) | |
download | mongo-3e53cfe1d7f31ad7fbae481d380110c9a041129c.tar.gz |
tostring better
-rw-r--r-- | db/btree.h | 2 | ||||
-rw-r--r-- | db/cursor.h | 6 | ||||
-rw-r--r-- | db/introspect.h | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/db/btree.h b/db/btree.h index f121f0728fb..617b8570b7c 100644 --- a/db/btree.h +++ b/db/btree.h @@ -199,7 +199,7 @@ public: virtual DiskLoc currLoc() { return !bucket.isNull() ? _currKeyNode().recordLoc : DiskLoc(); } virtual Record* _current() { return currLoc().rec(); } virtual BSONObj current() { return BSONObj(_current()); } - virtual const char * toString() { + virtual string toString() { return string("BtreeCursor ") + indexDetails.indexName(); } diff --git a/db/cursor.h b/db/cursor.h index d997de9a0f2..3713e529868 100644 --- a/db/cursor.h +++ b/db/cursor.h @@ -57,7 +57,7 @@ public: /* called before query getmore block is iterated */ virtual void checkLocation() { } - virtual const char * toString() { return "abstract?"; } + virtual string toString() { return "abstract?"; } /* used for multikey index traversal to avoid sending back dups. see JSMatcher::matches() */ set<DiskLoc> dups; @@ -104,7 +104,7 @@ public: BasicCursor(DiskLoc dl) : curr(dl) { init(); } BasicCursor() { init(); } - virtual const char * toString() { return "BasicCursor"; } + virtual string toString() { return "BasicCursor"; } virtual void tailResume() { if( state == TailPoint ) { @@ -142,6 +142,6 @@ public: ReverseCursor(DiskLoc dl) : BasicCursor(dl) { } ReverseCursor() { } - virtual const char * toString() { return "ReverseCursor"; } + virtual string toString() { return "ReverseCursor"; } }; diff --git a/db/introspect.h b/db/introspect.h index 7cb85c686a1..e1915050b0a 100644 --- a/db/introspect.h +++ b/db/introspect.h @@ -49,7 +49,7 @@ public: return false; } - virtual const char * toString() { return "SingleResultObjCursor"; } + virtual string toString() { return "SingleResultObjCursor"; } }; |