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

FileResourceInfo 类

文件资源信息

Definition

命名空间: TouchSocket.Dmtp.FileTransfer
程序集: TouchSocket.Dmtp (在 TouchSocket.Dmtp.dll 中) 版本:3.0.0+ccaf96084d09f972257496d1dd63b8ba3c1e44f0
C#
public class FileResourceInfo : PackageBase
Inheritance
Object    PackageBase    FileResourceInfo

构造函数

FileResourceInfo(IByteBlock) 从内存初始化资源
FileResourceInfo(FileInfo, Int32) 初始化FileResourceInfo对象的新实例。
FileResourceInfo(RemoteFileInfo, Int32) 初始化一个远程资源
FileResourceInfo(String, Int32) 初始化一个本地资源

属性

FileInfo 资源文件信息
FileSections 资源分块集合。
FileSectionSize 文件分块尺寸。
ResourceHandle 资源句柄唯一标识

方法

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。)
GetContinuationIndex 获取尝试续传时的索引。
GetFileSections 按文件块状态,获取块集合,如果没用找到任何元素,则返回空数组。
GetHashCodeServes as the default hash function.
(继承自 Object。)
GetTypeGets the Type of the current instance.
(继承自 Object。)
MemberwiseCloneCreates a shallow copy of the current Object.
(继承自 Object。)
PackageTByteBlock(TByteBlock) 打包。

重写的话,约定基类方法必须先执行


(继承自 PackageBase。)
PackageTByteBlock(TByteBlock) 打包。

重写的话,约定基类方法必须先执行


(重写 PackageBasePackageTByteBlock(TByteBlock))
ResetResourceHandle 重新设置资源标识。
SaveTByteBlockFileResourceInfo对象保存到内存。
ToStringReturns a string that represents the current object.
(继承自 Object。)
UnpackageTByteBlock(TByteBlock) 解包。

重写的话,约定基类方法必须先执行


(继承自 PackageBase。)
UnpackageTByteBlock(TByteBlock) 解包。

重写的话,约定基类方法必须先执行


(重写 PackageBaseUnpackageTByteBlock(TByteBlock))

扩展方法

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

参见