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

FileResourceLocator(FileResourceInfo, String, Boolean) 构造函数

根据资源信息和保存目录,初始化一个可写入的定位器。

Definition

命名空间: TouchSocket.Dmtp.FileTransfer
程序集: TouchSocket.Dmtp (在 TouchSocket.Dmtp.dll 中) 版本:3.0.0+ccaf96084d09f972257496d1dd63b8ba3c1e44f0
C#
public FileResourceLocator(
	FileResourceInfo fileResourceInfo,
	string locatorPath,
	bool overwrite = true
)

参数

fileResourceInfo  FileResourceInfo
资源信息对象,包含文件资源的详细信息。
locatorPath  String
定位器路径,即文件资源的保存目录。
overwrite  Boolean  (Optional)
是否覆盖现有文件,默认为 true。

异常

ArgumentException当 locatorPath 为 null 或空字符串时抛出。

参见