WriteModel
public enum WriteModel<CollectionType> where CollectionType : Decodable, CollectionType : Encodable
Enum encompassing operations that can be run as part of a bulkWrite.
-
A
deleteOne. Parameters:- A
BSONDocumentrepresenting the match criteria. options: OptionalDeleteModelOptions.
Declaration
Swift
case deleteOne(BSONDocument, options: DeleteModelOptions? = nil) - A
-
A
deleteMany. Parameters:- A
BSONDocumentrepresenting the match criteria. options: OptionalDeleteModelOptions.
Declaration
Swift
case deleteMany(BSONDocument, options: DeleteModelOptions? = nil) - A
-
An
insertOne. Parameters:- A
Tto insert.
Declaration
Swift
case insertOne(CollectionType) - A
-
A
replaceOne. Parameters:filter: ABSONDocumentrepresenting the match criteria.replacement: ATto use as the replacement value.options: OptionalReplaceOneModelOptions.
Declaration
Swift
case replaceOne(filter: BSONDocument, replacement: CollectionType, options: ReplaceOneModelOptions? = nil) -
An
updateOne. Parameters:filter: ABSONDocumentrepresenting the match criteria.update: ABSONDocumentcontaining update operators.options: OptionalUpdateModelOptions.
Declaration
Swift
case updateOne(filter: BSONDocument, update: BSONDocument, options: UpdateModelOptions? = nil) -
An
updateMany. Parameters:filter: ABSONDocumentrepresenting the match criteria.update: ABSONDocumentcontaining update operators.options: OptionalUpdateModelOptions.
Declaration
Swift
case updateMany(filter: BSONDocument, update: BSONDocument, options: UpdateModelOptions? = nil)
View on GitHub
Install in Dash
WriteModel Enumeration Reference