mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
access to raw resultFlags
This commit is contained in:
parent
7d9eebe983
commit
a2479cdf80
@ -672,6 +672,7 @@ namespace mongo {
|
||||
|
||||
void DBClientCursor::dataReceived() {
|
||||
QueryResult *qr = (QueryResult *) m->data;
|
||||
resultFlags = qr->resultFlags();
|
||||
if ( qr->resultFlags() & QueryResult::ResultFlag_CursorNotFound ) {
|
||||
// cursor id no longer valid at the server.
|
||||
assert( qr->cursorId == 0 );
|
||||
|
@ -178,6 +178,10 @@ namespace mongo {
|
||||
bool tailable() const {
|
||||
return (opts & Option_CursorTailable) != 0;
|
||||
}
|
||||
|
||||
bool hasResultFlag( int flag ){
|
||||
return resultFlags & flag;
|
||||
}
|
||||
|
||||
bool init();
|
||||
|
||||
@ -226,6 +230,7 @@ namespace mongo {
|
||||
int opts;
|
||||
auto_ptr<Message> m;
|
||||
|
||||
int resultFlags;
|
||||
long long cursorId;
|
||||
int nReturned;
|
||||
int pos;
|
||||
@ -234,7 +239,7 @@ namespace mongo {
|
||||
void requestMore();
|
||||
bool ownCursor_;
|
||||
};
|
||||
|
||||
|
||||
|
||||
/**
|
||||
The interface that any db connection should implement
|
||||
|
Loading…
Reference in New Issue
Block a user