다음을 통해 공유


TwinCollection.ClearAllMetadata Method

Definition

Clears all metadata out of the twin collection as well as the base metadata object.

public void ClearAllMetadata ();
member this.ClearAllMetadata : unit -> unit
Public Sub ClearAllMetadata ()

Remarks

This will remove all metadata from the base metadata object as well as the metadata for the twin collection. The difference from the ClearMetadata() method is this will also clear the underlying metadata object which will affect methods such as GetMetadata() and GetLastUpdatedVersion(). This method would be useful if you are performing any operations that require Microsoft.Azure.Devices.Shared.TwinCollection.TryGetMemberInternal(System.String,System.Object@) to return a Newtonsoft.Json.Linq.JToken regardless of the client you are using.

Applies to