XamlXmlWriterSettings.CloseOutput 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得或設定一個值,指定是否 XamlXmlWriter 應該立即 Dispose 關閉或執行其他操作,或是 XAML 寫入者應該在關閉前寫入緩衝區輸出。 使用此設定請謹慎使用;立即關閉可能導致無效的 XAML,無法再次載入。
public:
property bool CloseOutput { bool get(); void set(bool value); };
public bool CloseOutput { get; set; }
member this.CloseOutput : bool with get, set
Public Property CloseOutput As Boolean
屬性值
true 如果 XamlXmlWriter 立即關閉 a Dispose 或類似操作。
false 如果剩餘的緩衝區輸出在釋放前 XamlXmlWriter 被寫入。 預設值為 false。
備註
此設定影響 的邏輯XamlXmlWriter.Dispose,當 是 Close時呼叫 XmlWriterTextWriter 的 ;CloseOutputtrue或Flush當 是 XmlWriter時,則呼叫(同樣與基礎 TextWriter 或 CloseOutput)。false