Skip to content

enum

Action

pub enum Action {
    Find,
    FindOne,
    Count,
    Aggregate,
    InsertOne,
    UpdateOne,
    DeleteOne,
}

What a command does.

Variants

Find

Find

Find the documents matching filter.

FindOne

FindOne

Find the first document matching filter.

Count

Count

Count the documents matching filter.

Aggregate

Aggregate

Run an aggregation pipeline.

InsertOne

InsertOne

Insert document.

UpdateOne

UpdateOne

Apply the update in document to the first match of filter.

DeleteOne

DeleteOne

Delete the first document matching filter.

Methods

writes

pub fn writes(self) -> bool

Whether the action changes data.

Trait implementations