[−][src]Struct mongodb_helper::Database
Fields
db: Pool<MongodbConnectionManager>
Methods
impl Database
[src]
pub fn aggregate<R>(
&self,
collection: String,
pipeline: Vec<Document>,
options: Option<AggregateOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
[src]
&self,
collection: String,
pipeline: Vec<Document>,
options: Option<AggregateOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn find<R>(
&self,
collection: String,
filter: Option<Document>,
options: Option<FindOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
[src]
&self,
collection: String,
filter: Option<Document>,
options: Option<FindOptions>
) -> Result<Vec<R>, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn insert_one<D, R>(
&self,
collection: String,
document: D,
write_concern: Option<WriteConcern>
) -> Result<R, String> where
D: Serialize + Debug,
R: Deserialize<'r>,
[src]
&self,
collection: String,
document: D,
write_concern: Option<WriteConcern>
) -> Result<R, String> where
D: Serialize + Debug,
R: Deserialize<'r>,
impl Database
[src]
pub fn find_one_and_update<R>(
&self,
collection: String,
filter: Document,
update: Document,
options: Option<FindOneAndUpdateOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
[src]
&self,
collection: String,
filter: Document,
update: Document,
options: Option<FindOneAndUpdateOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn find_one_and_delete<R>(
&self,
collection: String,
filter: Document,
options: Option<FindOneAndDeleteOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
[src]
&self,
collection: String,
filter: Document,
options: Option<FindOneAndDeleteOptions>
) -> Result<R, String> where
R: Deserialize<'r>,
impl Database
[src]
pub fn delete_many(
&self,
collection: String,
filter: Document,
write_concern: Option<WriteConcern>
) -> Result<i32, String>
[src]
&self,
collection: String,
filter: Document,
write_concern: Option<WriteConcern>
) -> Result<i32, String>
impl Database
[src]
pub fn update_many(
&self,
collection: String,
filter: Document,
update: Document,
options: Option<UpdateOptions>
) -> Result<i32, String>
[src]
&self,
collection: String,
filter: Document,
update: Document,
options: Option<UpdateOptions>
) -> Result<i32, String>
Trait Implementations
Auto Trait Implementations
Blanket Implementations
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> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for 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> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
U: TryFrom<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self