XNode.WriteToAsync(XmlWriter, CancellationToken) 方法

定義

將目前的節點寫入 XmlWriterWrites the current node to an XmlWriter.

public:
 abstract System::Threading::Tasks::Task ^ WriteToAsync(System::Xml::XmlWriter ^ writer, System::Threading::CancellationToken cancellationToken);
public abstract System.Threading.Tasks.Task WriteToAsync (System.Xml.XmlWriter writer, System.Threading.CancellationToken cancellationToken);
abstract member WriteToAsync : System.Xml.XmlWriter * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public MustOverride Function WriteToAsync (writer As XmlWriter, cancellationToken As CancellationToken) As Task

參數

writer
XmlWriter

要寫入目前節點的寫入器。The writer to write the current node into.

cancellationToken
CancellationToken

可用來要求取消非同步作業的權杖。A token that can be used to request cancellation of the asynchronous operation.

傳回

Task

代表非同步寫入作業的工作。A task representing the asynchronous write operation.

適用於