[−][src]Trait avocado::db::DatabaseExt
Methods augmenting MongoDB ThreadedDatabase
types.
Provided Methods
fn existing_collection<T: Doc>(&self) -> Collection<T>
Returns an existing collection without dropping/recreating it.
fn empty_collection<T: Doc>(&self) -> Result<Collection<T>>
Creates a fresh, empty collection. Drops any existing collection
with the same name. Recreates the collection with the $jsonSchema
validator based on the BsonSchema
impl of the document type.
fn empty_collection_novalidate<T: Doc>(&self) -> Result<Collection<T>>
Creates a fresh, empty collection. Drops any existing collection with the same name. Recreates the collection without the BSON schema validator.
Implementors
impl<T: ThreadedDatabase> DatabaseExt for T
[src]
impl<T: ThreadedDatabase> DatabaseExt for T
fn existing_collection<T: Doc>(&self) -> Collection<T>
[src]
fn existing_collection<T: Doc>(&self) -> Collection<T>
fn empty_collection<T: Doc>(&self) -> Result<Collection<T>>
[src]
fn empty_collection<T: Doc>(&self) -> Result<Collection<T>>
fn empty_collection_novalidate<T: Doc>(&self) -> Result<Collection<T>>
[src]
fn empty_collection_novalidate<T: Doc>(&self) -> Result<Collection<T>>