Exemple #1
0
    void ClientCursor::setLastLoc_inlock(DiskLoc L) {
        verify( _pos != -2 ); // defensive - see ~ClientCursor

        if ( L == _lastLoc )
            return;

        CCByLoc& bl = byLoc();

        if ( !_lastLoc.isNull() ) {
            bl.erase( ByLocKey( _lastLoc, _cursorid ) );
        }

        if ( !L.isNull() )
            bl[ByLocKey(L,_cursorid)] = this;
        _lastLoc = L;
    }
Exemple #2
0
    void ClientCursor::setLastLoc_inlock(DiskLoc L) {
        verify(NULL == _runner.get());
        verify( _pos != -2 ); // defensive - see ~ClientCursor

        if (L == _lastLoc) { return; }
        CCByLoc& bl = _db->ccByLoc();

        if (!_lastLoc.isNull()) {
            bl.erase(ByLocKey(_lastLoc, _cursorid));
        }

        if (!L.isNull()) {
            bl[ByLocKey(L,_cursorid)] = this;
        }

        _lastLoc = L;
    }