saveDocumentWithConflictHandler abstract method
- @Deprecated('Use defaultCollection.saveDocumentWithConflictHandler instead.')
- @override
- MutableDocument document,
- SaveConflictHandler conflictHandler
override
Saves a document
to this database, resolving conflicts with a
conflictHandler
.
When write operations are executed concurrently and if conflicts occur,
the conflictHandler
will be called. Use the conflict handler to directly
edit the Document to resolve the conflict. When the conflict handler
returns true
, the save method will save the edited document as the
resolved document. If the conflict handler returns false
, the save
operation will be canceled with false
as the result. If the conflict
handler returns true
or there is no conflict the result is true
.
Implementation
@Deprecated('Use defaultCollection.saveDocumentWithConflictHandler instead.')
@override
Future<bool> saveDocumentWithConflictHandler(
MutableDocument document,
SaveConflictHandler conflictHandler,
);