一款简单易用的基础网络通讯组件库。

DmtpRemoteStream 类

远程流访问

Definition

命名空间: TouchSocket.Dmtp.RemoteStream
程序集: TouchSocketPro.Dmtp (在 TouchSocketPro.Dmtp.dll 中) 版本:3.0.0+ccaf96084d09f972257496d1dd63b8ba3c1e44f0
C#
public abstract class DmtpRemoteStream : Stream
Inheritance
Object    MarshalByRefObject    Stream    DmtpRemoteStream

构造函数

DmtpRemoteStream初始化 DmtpRemoteStream 类的一个新实例

属性

CanReadWhen overridden in a derived class, gets a value indicating whether the current stream supports reading.
(继承自 Stream。)
CanSeekWhen overridden in a derived class, gets a value indicating whether the current stream supports seeking.
(继承自 Stream。)
CanTimeoutGets a value that determines whether the current stream can time out.
(继承自 Stream。)
CanWriteWhen overridden in a derived class, gets a value indicating whether the current stream supports writing.
(继承自 Stream。)
DataCompressor 数据压缩机。
LengthWhen overridden in a derived class, gets the length in bytes of the stream.
(继承自 Stream。)
Metadata 元数据
PositionWhen overridden in a derived class, gets or sets the position within the current stream.
(继承自 Stream。)
ReadTimeoutGets or sets a value, in milliseconds, that determines how long the stream will attempt to read before timing out.
(继承自 Stream。)
Timeout 单次通信超时时长,默认10*1000毫秒。
TryCount 重试次数,默认3。
WriteTimeoutGets or sets a value, in milliseconds, that determines how long the stream will attempt to write before timing out.
(继承自 Stream。)

方法

BeginReadBegins an asynchronous read operation. (Consider using ReadAsync(Byte, Int32, Int32) instead.)
(继承自 Stream。)
BeginWriteBegins an asynchronous write operation. (Consider using WriteAsync(Byte, Int32, Int32) instead.)
(继承自 Stream。)
CloseCloses the current stream and releases any resources (such as sockets and file handles) associated with the current stream. Instead of calling this method, ensure that the stream is properly disposed.
(继承自 Stream。)
CopyTo(Stream)Reads the bytes from the current stream and writes them to another stream.
(继承自 Stream。)
CopyTo(Stream, Int32)Reads the bytes from the current stream and writes them to another stream, using a specified buffer size.
(继承自 Stream。)
CopyToAsync(Stream)Asynchronously reads the bytes from the current stream and writes them to another stream.
(继承自 Stream。)
CopyToAsync(Stream, Int32)Asynchronously reads the bytes from the current stream and writes them to another stream, using a specified buffer size.
(继承自 Stream。)
CopyToAsync(Stream, CancellationToken)Asynchronously reads the bytes from the current stream and writes them to another stream, using a specified cancellation token.
(继承自 Stream。)
CopyToAsync(Stream, Int32, CancellationToken)Asynchronously reads the bytes from the current stream and writes them to another stream, using a specified buffer size and cancellation token.
(继承自 Stream。)
CreateWaitHandleAllocates a WaitHandle object.
(继承自 Stream。)
已过时。
DisposeReleases all resources used by the Stream.
(继承自 Stream。)
Dispose(Boolean)Releases the unmanaged resources used by the Stream and optionally releases the managed resources.
(继承自 Stream。)
DisposeAsyncAsynchronously releases the unmanaged resources used by the Stream.
(继承自 Stream。)
EndReadWaits for the pending asynchronous read to complete. (Consider using ReadAsync(Byte, Int32, Int32) instead.)
(继承自 Stream。)
EndWriteEnds an asynchronous write operation. (Consider using WriteAsync(Byte, Int32, Int32) instead.)
(继承自 Stream。)
EqualsDetermines whether the specified object is equal to the current object.
(继承自 Object。)
FinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(继承自 Object。)
FlushWhen overridden in a derived class, clears all buffers for this stream and causes any buffered data to be written to the underlying device.
(继承自 Stream。)
FlushAsyncAsynchronously clears all buffers for this stream and causes any buffered data to be written to the underlying device.
(继承自 Stream。)
FlushAsync(CancellationToken)Asynchronously clears all buffers for this stream, causes any buffered data to be written to the underlying device, and monitors cancellation requests.
(继承自 Stream。)
GetHashCodeServes as the default hash function.
(继承自 Object。)
GetLifetimeServiceRetrieves the current lifetime service object that controls the lifetime policy for this instance.
(继承自 MarshalByRefObject。)
已过时。
GetTypeGets the Type of the current instance.
(继承自 Object。)
InitializeLifetimeServiceObtains a lifetime service object to control the lifetime policy for this instance.
(继承自 MarshalByRefObject。)
已过时。
MemberwiseCloneCreates a shallow copy of the current Object.
(继承自 Object。)
MemberwiseClone(Boolean)Creates a shallow copy of the current MarshalByRefObject object.
(继承自 MarshalByRefObject。)
ObjectInvariantProvides support for a Contract.
(继承自 Stream。)
已过时。
Read(SpanByte)When overridden in a derived class, reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.
(继承自 Stream。)
Read(Byte, Int32, Int32)When overridden in a derived class, reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.
(继承自 Stream。)
ReadAsync(MemoryByte, CancellationToken)Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests.
(继承自 Stream。)
ReadAsync(Byte, Int32, Int32)Asynchronously reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.
(继承自 Stream。)
ReadAsync(Byte, Int32, Int32, CancellationToken)Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests.
(继承自 Stream。)
ReadByteReads a byte from the stream and advances the position within the stream by one byte, or returns -1 if at the end of the stream.
(继承自 Stream。)
SeekWhen overridden in a derived class, sets the position within the current stream.
(继承自 Stream。)
SetLengthWhen overridden in a derived class, sets the length of the current stream.
(继承自 Stream。)
SetLengthAsync 异步设置当前对象的长度。
ToStringReturns a string that represents the current object.
(继承自 Object。)
Write(ReadOnlySpanByte)When overridden in a derived class, writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.
(继承自 Stream。)
Write(Byte, Int32, Int32)When overridden in a derived class, writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.
(继承自 Stream。)
WriteAsync(ReadOnlyMemoryByte, CancellationToken)Asynchronously writes a sequence of bytes to the current stream, advances the current position within this stream by the number of bytes written, and monitors cancellation requests.
(继承自 Stream。)
WriteAsync(Byte, Int32, Int32)Asynchronously writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.
(继承自 Stream。)
WriteAsync(Byte, Int32, Int32, CancellationToken)Asynchronously writes a sequence of bytes to the current stream, advances the current position within this stream by the number of bytes written, and monitors cancellation requests.
(继承自 Stream。)
WriteByteWrites a byte to the current position in the stream and advances the position within the stream by one byte.
(继承自 Stream。)

扩展方法

Map
(由 Mapper 定义。)
Map
(由 Mapper 定义。)
MapTTarget
(由 Mapper 定义。)
ToJsonString 转换为Json
(由 SerializeConvert 定义。)

参见