CanBeZeroStream
Namespace: UAssetAPI
Pass-through stream for detecting non-zero byte writes for CanBeZero.
public class CanBeZeroStream : System.IO.Stream, System.IDisposable, System.IAsyncDisposable
Inheritance Object → MarshalByRefObject → Stream → CanBeZeroStream
Implements IDisposable, IAsyncDisposable
Fields
InnerStream
public Stream InnerStream;
HasWrittenNonZero
public bool HasWrittenNonZero;
Properties
Position
public long Position { get; set; }
Property Value
Length
public long Length { get; }
Property Value
CanRead
public bool CanRead { get; }
Property Value
CanSeek
public bool CanSeek { get; }
Property Value
CanWrite
public bool CanWrite { get; }
Property Value
CanTimeout
public bool CanTimeout { get; }
Property Value
ReadTimeout
public int ReadTimeout { get; set; }
Property Value
WriteTimeout
public int WriteTimeout { get; set; }
Property Value
Constructors
CanBeZeroStream(Stream)
public CanBeZeroStream(Stream innerStream)
Parameters
innerStream Stream
Methods
Read(Byte[], Int32, Int32)
public int Read(Byte[] buffer, int offset, int count)
Parameters
buffer Byte[]
offset Int32
count Int32
Returns
Write(Byte[], Int32, Int32)
public void Write(Byte[] buffer, int offset, int count)
Parameters
buffer Byte[]
offset Int32
count Int32
Flush()
public void Flush()
Seek(Int64, SeekOrigin)
public long Seek(long offset, SeekOrigin origin)
Parameters
offset Int64
origin SeekOrigin
Returns
SetLength(Int64)
public void SetLength(long value)
Parameters
value Int64
Dispose(Boolean)
protected void Dispose(bool disposing)
Parameters
disposing Boolean
ReadAsync(Byte[], Int32, Int32, CancellationToken)
public Task<int> ReadAsync(Byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Parameters
buffer Byte[]
offset Int32
count Int32
cancellationToken CancellationToken
Returns
WriteAsync(Byte[], Int32, Int32, CancellationToken)
public Task WriteAsync(Byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Parameters
buffer Byte[]
offset Int32
count Int32
cancellationToken CancellationToken
Returns
FlushAsync(CancellationToken)
public Task FlushAsync(CancellationToken cancellationToken)
Parameters
cancellationToken CancellationToken