mongo::BSONObjExternalSorter Class Reference

#include <extsort.h>

List of all members.

Classes

class  FileIterator
class  Iterator
class  MyCmp

Public Types

typedef pair< BSONObj, DiskLocData
typedef FastArray< DataInMemory

Public Member Functions

void add (const BSONObj &o, int a, int b)
void add (const BSONObj &o, const DiskLoc &loc)
 BSONObjExternalSorter (const BSONObj &order=BSONObj(), long maxFileSize=1024 *1024 *100)
long getCurSizeSoFar ()
void hintNumObjects (long long numObjects)
auto_ptr< Iteratoriterator ()
int numFiles ()
void sort ()
 ~BSONObjExternalSorter ()

Private Member Functions

void _sortInMem ()
void finishMap ()
void sort (string file)

Static Private Member Functions

static int extSortComp (const void *lv, const void *rv)

Private Attributes

int _arraySize
InMemory_cur
long _curSizeSoFar
list< string > _files
long _maxFilesize
BSONObj _order
path _root
bool _sorted

Static Private Attributes

static unsigned long long _compares
static BSONObj extSortOrder

Detailed Description

for sorting by BSONObj and attaching a value

Definition at line 32 of file extsort.h.


Member Typedef Documentation

Definition at line 29 of file extsort.h.

Definition at line 75 of file extsort.h.


Constructor & Destructor Documentation

mongo::BSONObjExternalSorter::BSONObjExternalSorter ( const BSONObj order = BSONObj(),
long  maxFileSize = 1024 *1024 *100 
)
mongo::BSONObjExternalSorter::~BSONObjExternalSorter (  ) 

Member Function Documentation

void mongo::BSONObjExternalSorter::_sortInMem (  )  [private]
void mongo::BSONObjExternalSorter::add ( const BSONObj o,
int  a,
int  b 
) [inline]

Definition at line 99 of file extsort.h.

void mongo::BSONObjExternalSorter::add ( const BSONObj o,
const DiskLoc loc 
)
static int mongo::BSONObjExternalSorter::extSortComp ( const void *  lv,
const void *  rv 
) [inline, static, private]

Definition at line 34 of file extsort.h.

void mongo::BSONObjExternalSorter::finishMap (  )  [private]
long mongo::BSONObjExternalSorter::getCurSizeSoFar (  )  [inline]

Definition at line 115 of file extsort.h.

void mongo::BSONObjExternalSorter::hintNumObjects ( long long  numObjects  )  [inline]

Definition at line 117 of file extsort.h.

auto_ptr<Iterator> mongo::BSONObjExternalSorter::iterator (  )  [inline]

Definition at line 106 of file extsort.h.

int mongo::BSONObjExternalSorter::numFiles (  )  [inline]

Definition at line 111 of file extsort.h.

void mongo::BSONObjExternalSorter::sort ( string  file  )  [private]
void mongo::BSONObjExternalSorter::sort (  ) 

Member Data Documentation

Definition at line 133 of file extsort.h.

unsigned long long mongo::BSONObjExternalSorter::_compares [static, private]

Definition at line 140 of file extsort.h.

Definition at line 134 of file extsort.h.

Definition at line 135 of file extsort.h.

list<string> mongo::BSONObjExternalSorter::_files [private]

Definition at line 137 of file extsort.h.

Definition at line 130 of file extsort.h.

Definition at line 129 of file extsort.h.

Definition at line 131 of file extsort.h.

Definition at line 138 of file extsort.h.

Definition at line 32 of file extsort.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


mongodb
Author(s): Nate Koenig
autogenerated on Fri Jan 11 12:15:53 2013