Method UploadFromBytesAsync
UploadFromBytesAsync(TFileId, string, byte[], GridFSUploadOptions, CancellationToken)
Uploads a file (or a new revision of a file) to GridFS.
public Task UploadFromBytesAsync(TFileId id, string filename, byte[] source, GridFSUploadOptions options = null, CancellationToken cancellationToken = default)
Parameters
id
TFileIdThe file id.
filename
stringThe filename.
source
byte[]The source.
options
GridFSUploadOptionsThe options.
cancellationToken
CancellationTokenThe cancellation token.
Returns
- Task
A Task.