public class DBApiLayer extends DB
| Modifier | Constructor and Description |
|---|---|
protected |
DBApiLayer(Mongo mongo,
String name,
DBConnector connector) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanCursors(boolean force) |
protected com.mongodb.DBApiLayer.MyCollection |
doGetCollection(String name)
Returns the collection represented by the string <dbName>.<collectionName>.
|
void |
requestDone()
ends the current "consistent request"
|
void |
requestEnsureConnection()
ensure that a connection is assigned to the current "consistent request" (from primary pool, if connected to a replica set)
|
void |
requestStart()
starts a new "consistent request".
|
addOption, addUser, addUser, authenticate, authenticateCommand, collectionExists, command, command, command, command, command, command, command, command, createCollection, doEval, dropDatabase, eval, forceError, getCollection, getCollectionFromString, getCollectionNames, getLastError, getLastError, getLastError, getMongo, getName, getOptions, getPreviousError, getReadPreference, getSisterDB, getStats, getWriteConcern, isAuthenticated, removeUser, resetError, resetOptions, setOptions, setReadOnly, setReadPreference, setWriteConcern, slaveOk, toStringprotected DBApiLayer(Mongo mongo, String name, DBConnector connector)
mongo - the Mongo instancename - the database nameconnector - the connectorpublic void requestStart()
DBrequestStart in class DBpublic void requestDone()
DBrequestDone in class DBpublic void requestEnsureConnection()
DBrequestEnsureConnection in class DBprotected com.mongodb.DBApiLayer.MyCollection doGetCollection(String name)
DBdoGetCollection in class DBname - the name of the collectionpublic void cleanCursors(boolean force)
cleanCursors in class DBforce - true if should clean regardless of number of dead cursorsMongoException