Package org.lightcouch
Class CouchDbContext
java.lang.Object
org.lightcouch.CouchDbContext
Contains database server specific APIs.
- Since:
- 0.0.2
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate CouchDbClientBase
private static final org.apache.commons.logging.Log
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
compact()
Triggers a database compact request.void
Requests CouchDB creates a new database; if one doesn't exist.void
Requests CouchDB deletes a database.void
Requests the database commits any recent changes to disk.info()
uuids
(long count) Request a database sends a list of UUIDs.
-
Field Details
-
log
private static final org.apache.commons.logging.Log log -
dbc
-
-
Constructor Details
-
CouchDbContext
CouchDbContext(CouchDbClientBase dbc, CouchDbProperties props)
-
-
Method Details
-
deleteDB
Requests CouchDB deletes a database.- Parameters:
dbName
- The database nameconfirm
- A confirmation string with the value: delete database
-
createDB
Requests CouchDB creates a new database; if one doesn't exist.- Parameters:
dbName
- The Database name
-
getAllDbs
- Returns:
- All Server databases.
-
info
- Returns:
CouchDbInfo
Containing the DB server info.
-
serverVersion
- Returns:
- DB Server version.
-
compact
public void compact()Triggers a database compact request. -
ensureFullCommit
public void ensureFullCommit()Requests the database commits any recent changes to disk. -
uuids
Request a database sends a list of UUIDs.- Parameters:
count
- The count of UUIDs.- Returns:
- a list of UUIDs
-