Method SaveAsync
- Namespace
- IntentSharp.Documents
- Assembly
- IntentSharp.dll
SaveAsync(DocumentSave, CancellationToken)
Stores a new version of a document and, when Activate is true, makes it the running version. Returns the new version.
public ValueTask<DocumentVersion> SaveAsync(DocumentSave save, CancellationToken ct = default)
Parameters
saveDocumentSaveThe text, author and options of the new version.
ctCancellationTokenCancels the call.
Returns
- ValueTask<DocumentVersion>
Exceptions
- ArgumentNullException
saveis null.- ArgumentException
The save's Id is a default DocumentId, which names no document, or its text or author is null.
- DocumentConflictException
BasedOn is set and is not the running sequence. Nothing was stored.