PipeWriter Sınıf

Tanım

Verilerin yazılabileceği bir işlem hattı sağlayan bir sınıf tanımlar.Defines a class that provides a pipeline to which data can be written.

public ref class PipeWriter abstract : System::Buffers::IBufferWriter<System::Byte>
public abstract class PipeWriter : System.Buffers.IBufferWriter<byte>
type PipeWriter = class
    interface IBufferWriter<byte>
Public MustInherit Class PipeWriter
Implements IBufferWriter(Of Byte)
Devralma
PipeWriter
Uygulamalar

Oluşturucular

PipeWriter()

Sınıfının yeni bir örneğini başlatır.Initializes a new instance of the class.

Yöntemler

Advance(Int32)

PipeWriterBu bytes baytların çıkışa yazıldığını bildirir Span<T> veya Memory<T> .Notifies the PipeWriter that bytes bytes were written to the output Span<T> or Memory<T>. Advance(Int32)Daha fazla veri yazmaya devam etmek için çağrıldıktan sonra yeni bir arabellek istemeniz gerekir; daha önce elde edilen bir arabelleğe yazılamaz.You must request a new buffer after calling Advance(Int32) to continue writing more data; you cannot write to a previously acquired buffer.

AsStream(Boolean)

StreamÖğesinin gösterimini döndürür PipeWriter .Returns a Stream representation of the PipeWriter.

CancelPendingFlush()

FlushAsync(CancellationToken) WriteAsync(ReadOnlyMemory<Byte>, CancellationToken) İşlemin tamamlanmasına ve tamamlanmamasına neden olmadan bekleyen veya işlemi iptal eder PipeWriter .Cancels the pending FlushAsync(CancellationToken) or WriteAsync(ReadOnlyMemory<Byte>, CancellationToken) operation without causing the operation to throw and without completing the PipeWriter. Bekleyen bir işlem yoksa, bu işlem sonraki işlemi iptal eder.If there is no pending operation, this cancels the next operation.

Complete(Exception)

PipeWriterTamamlanmış olarak işaretler, buna başka öğe yazılmayacak.Marks the PipeWriter as being complete, meaning no more items will be written to it.

CompleteAsync(Exception)

Geçerli kanal yazıcısı örneğini tamamlanmış olarak işaretler, yani bu, üzerine daha fazla veri yazılmaz.Marks the current pipe writer instance as being complete, meaning no more data will be written to it.

CopyFromAsync(Stream, CancellationToken)

Belirtilen akıştan baytları zaman uyumsuz olarak okur ve öğesine yazar PipeWriter .Asynchronously reads the bytes from the specified stream and writes them to the PipeWriter.

Create(Stream, StreamPipeWriterOptions)

Belirtilen bir PipeWriter sarmalama oluşturur Stream .Creates a PipeWriter wrapping the specified Stream.

Equals(Object)

Belirtilen nesnenin geçerli nesneye eşit olup olmadığını belirler.Determines whether the specified object is equal to the current object.

(Devralındığı yer: Object)
FlushAsync(CancellationToken)

Yazılan baytları için kullanılabilir PipeReader ve ReadAsync(CancellationToken) devamlılık yapar.Makes bytes written available to PipeReader and runs ReadAsync(CancellationToken) continuation.

GetHashCode()

Varsayılan karma işlevi olarak işlev görür.Serves as the default hash function.

(Devralındığı yer: Object)
GetMemory(Int32)

Memory<T>Parametresi tarafından belirtildiği gibi, en az istenen boyutta yazmak için bir döndürür sizeHint .Returns a Memory<T> to write to that is at least the requested size, as specified by the sizeHint parameter.

GetSpan(Int32)

Span<T>Parametresi tarafından belirtildiği gibi, en az istenen boyutta yazmak için bir döndürür sizeHint .Returns a Span<T> to write to that is at least the requested size, as specified by the sizeHint parameter.

GetType()

TypeGeçerli örneği alır.Gets the Type of the current instance.

(Devralındığı yer: Object)
MemberwiseClone()

Geçerli bir basit kopyasını oluşturur Object .Creates a shallow copy of the current Object.

(Devralındığı yer: Object)
OnReaderCompleted(Action<Exception,Object>, Object)
Kullanımdan kalktı.

Kanal tarafı tamamlandığında yürütülen bir geri aramayı kaydeder PipeReader .Registers a callback that executes when the PipeReader side of the pipe is completed.

ToString()

Geçerli nesneyi temsil eden dizeyi döndürür.Returns a string that represents the current object.

(Devralındığı yer: Object)
WriteAsync(ReadOnlyMemory<Byte>, CancellationToken)

Belirtilen bayt bellek aralığını kanala yazar ve verileri ' a erişilebilir hale getirir PipeReader .Writes the specified byte memory range to the pipe and makes data accessible to the PipeReader.

Şunlara uygulanır