diff options
author | dwight <dwight@Dwights-MacBook-2.local> | 2009-02-08 21:00:26 -0500 |
---|---|---|
committer | dwight <dwight@Dwights-MacBook-2.local> | 2009-02-08 21:00:26 -0500 |
commit | cf65d861310dcca50c0d6bd8d26187d33f4a4cb1 (patch) | |
tree | 43ff3f30682e0c5ca4526ab03ffd3808788de469 | |
parent | c780a112c52a9926d292456b7940c5ba4b4dc9e3 (diff) | |
download | mongo-cf65d861310dcca50c0d6bd8d26187d33f4a4cb1.tar.gz |
doxygen for bsonobjiterator
-rw-r--r-- | db/jsobj.h | 6 | ||||
-rw-r--r-- | dbgrid/dbgrid.vcproj | 4 |
2 files changed, 7 insertions, 3 deletions
diff --git a/db/jsobj.h b/db/jsobj.h index 6543064f6b7..9e754eb2f55 100644 --- a/db/jsobj.h +++ b/db/jsobj.h @@ -985,13 +985,15 @@ namespace mongo { }; - /* iterator for a BSONObj + /** iterator for a BSONObj Note each BSONObj ends with an EOO element: so you will get more() on an empty object, although next().eoo() will be true. */ class BSONObjIterator { public: + /** Create an iterator for a BSON object. + */ BSONObjIterator(const BSONObj& jso) { int sz = jso.objsize(); if ( sz == 0 ) { @@ -1001,9 +1003,11 @@ namespace mongo { pos = jso.objdata() + 4; theend = jso.objdata() + sz; } + /** @return true if more elements exist to be enumerated. */ bool more() { return pos < theend; } + /** @return the next element in the object. For the final element, element.eoo() will be true. */ BSONElement next( bool checkEnd = false ) { assert( pos < theend ); BSONElement e( pos, checkEnd ? theend - pos : -1 ); diff --git a/dbgrid/dbgrid.vcproj b/dbgrid/dbgrid.vcproj index 8fc514dbea2..6d3e790b8f3 100644 --- a/dbgrid/dbgrid.vcproj +++ b/dbgrid/dbgrid.vcproj @@ -330,11 +330,11 @@ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
- RelativePath=".\ConfigServer.cpp"
+ RelativePath=".\commands.cpp"
>
</File>
<File
- RelativePath=".\dbgrid_commands.cpp"
+ RelativePath=".\ConfigServer.cpp"
>
</File>
<File
|