JsonElement.Clone 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
會獲得一個 JsonElement,可以安全地儲存在原始 JsonDocumentJsonElement 的壽命之後。
public:
System::Text::Json::JsonElement Clone();
public System.Text.Json.JsonElement Clone();
member this.Clone : unit -> System.Text.Json.JsonElement
Public Function Clone () As JsonElement
傳回
一個可以安全儲存在原始 JsonDocument.
備註
如果這JsonElement本身是先前Clone呼叫的輸出,或是先前呼叫 的輸出中JsonElementClone包含的值,此方法不會產生額外的記憶體配置。