[−][src]Struct mongodb_helper::Database
Fields
db: Database
Methods
impl Database
[src]
pub fn aggregate<R>(
&self,
collection: &str,
pipeline: Vec<Document>,
options: Option<AggregateOptions>
) -> Result<Vec<R>, DecoderError> where
R: Deserialize<'r>,
[src]
&self,
collection: &str,
pipeline: Vec<Document>,
options: Option<AggregateOptions>
) -> Result<Vec<R>, DecoderError> where
R: Deserialize<'r>,
impl Database
[src]
pub fn count(
&self,
collection: &str,
filter: Option<Document>,
options: Option<CountOptions>
) -> Result<i64, DecoderError>
[src]
&self,
collection: &str,
filter: Option<Document>,
options: Option<CountOptions>
) -> Result<i64, DecoderError>
impl Database
[src]
pub fn delete_many(
&self,
collection: &str,
filter: Document,
write_concern: Option<DeleteOptions>
) -> Result<i64, String>
[src]
&self,
collection: &str,
filter: Document,
write_concern: Option<DeleteOptions>
) -> Result<i64, String>
impl Database
[src]
pub fn find<R>(
&self,
collection: &str,
filter: Option<Document>,
options: Option<FindOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
[src]
&self,
collection: &str,
filter: Option<Document>,
options: Option<FindOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn find_one<R>(
&self,
collection: &str,
filter: Option<Document>,
options: Option<FindOneOptions>
) -> Result<Option<R>, String> where
R: Deserialize<'r>,
[src]
&self,
collection: &str,
filter: Option<Document>,
options: Option<FindOneOptions>
) -> Result<Option<R>, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn find_one_and_delete<R>(
&self,
collection: &str,
filter: Document,
options: Option<FindOneAndDeleteOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
[src]
&self,
collection: &str,
filter: Document,
options: Option<FindOneAndDeleteOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn find_one_and_update<R>(
&self,
collection: &str,
filter: Document,
update: Document,
options: Option<FindOneAndUpdateOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
[src]
&self,
collection: &str,
filter: Document,
update: Document,
options: Option<FindOneAndUpdateOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn insert_many<D, R>(
&self,
collection: &str,
list_document: Vec<D>,
options: Option<InsertManyOptions>
) -> Result<Vec<R>, String> where
D: Serialize,
R: Deserialize<'r>,
[src]
&self,
collection: &str,
list_document: Vec<D>,
options: Option<InsertManyOptions>
) -> Result<Vec<R>, String> where
D: Serialize,
R: Deserialize<'r>,
impl Database
[src]
pub fn insert_one<D, R>(
&self,
collection: &str,
document: D,
options: Option<InsertOneOptions>
) -> Result<R, String> where
D: Serialize,
R: Deserialize<'r>,
[src]
&self,
collection: &str,
document: D,
options: Option<InsertOneOptions>
) -> Result<R, String> where
D: Serialize,
R: Deserialize<'r>,
impl Database
[src]
pub fn update_many(
&self,
collection: &str,
filter: Document,
update: Document,
options: Option<UpdateOptions>
) -> Result<i64, String>
[src]
&self,
collection: &str,
filter: Document,
update: Document,
options: Option<UpdateOptions>
) -> Result<i64, String>
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Database
impl Send for Database
impl Sync for Database
impl Unpin for Database
impl !UnwindSafe for Database
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
U: TryFrom<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,