Table of Contents

Method UploadFromBytes

Namespace
MongoDB.Driver.GridFS
Assembly
MongoDB.Driver.dll

UploadFromBytes(TFileId, string, byte[], GridFSUploadOptions, CancellationToken)

Uploads a file (or a new revision of a file) to GridFS.

void UploadFromBytes(TFileId id, string filename, byte[] source, GridFSUploadOptions options = null, CancellationToken cancellationToken = default)

Parameters

id TFileId

The file id.

filename string

The filename.

source byte[]

The source.

options GridFSUploadOptions

The options.

cancellationToken CancellationToken

The cancellation token.