Freigeben über


AppendBlobClient.CreateIfNotExists Methode

Definition

Der CreateIfNotExists(AppendBlobCreateOptions, CancellationToken) Vorgang erstellt ein neues Anfügeblob der Länge 0. Wenn das Anfügeblob bereits vorhanden ist, bleibt der Inhalt des vorhandenen Anfügeblobs unverändert. Um dem Anfügeblob Inhalte hinzuzufügen, rufen Sie den Vorgang auf Azure.Storage.Blobs.Specialized.AppendBlobClient.AppendBlockAsync(System.IO.Stream,System.Byte[],Azure.Storage.Blobs.Models.AppendBlobRequestConditions,System.IProgress{System.Int64},System.Threading.CancellationToken) .

Weitere Informationen finden Sie unter Legen Sie Blob fest.

public virtual Azure.Response<Azure.Storage.Blobs.Models.BlobContentInfo> CreateIfNotExists (Azure.Storage.Blobs.Models.AppendBlobCreateOptions options, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateIfNotExists : Azure.Storage.Blobs.Models.AppendBlobCreateOptions * System.Threading.CancellationToken -> Azure.Response<Azure.Storage.Blobs.Models.BlobContentInfo>
override this.CreateIfNotExists : Azure.Storage.Blobs.Models.AppendBlobCreateOptions * System.Threading.CancellationToken -> Azure.Response<Azure.Storage.Blobs.Models.BlobContentInfo>
Public Overridable Function CreateIfNotExists (options As AppendBlobCreateOptions, Optional cancellationToken As CancellationToken = Nothing) As Response(Of BlobContentInfo)

Parameter

options
AppendBlobCreateOptions

Optionale Parameter.

cancellationToken
CancellationToken

Optional CancellationToken zur Weitergabe von Benachrichtigungen, dass der Vorgang abgebrochen werden soll.

Gibt zurück

Wenn das Anfügeblob noch nicht vorhanden ist, wird das Response<T> neu erstellte Anfügeblob beschrieben. Andernfalls null.

Hinweise

Ein RequestFailedException wird ausgelöst, wenn ein Fehler auftritt.

Gilt für: