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

FileStorage 类

文件存储器。在该存储器中,读写线程安全。

Definition

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

属性

AccessTime 最后访问时间。
AccessTimeout 访问超时时间。默认60s
FileAccess 访问属性
FileInfo 文件信息
FileStream 文件流。 一般情况下,请不要直接访问该对象。否则有可能会产生不可预测的错误。
Length 文件长度
Path 文件路径
Reference 引用次数。

方法

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。)
Flush 写入时清空缓存区
GetHashCodeServes as the default hash function.
(继承自 Object。)
GetTypeGets the Type of the current instance.
(继承自 Object。)
MemberwiseCloneCreates a shallow copy of the current Object.
(继承自 Object。)
Read 从当前文件中读取字节。
ToStringReturns a string that represents the current object.
(继承自 Object。)
TryReleaseFile 减少引用次数,并尝试释放流。
Write 写入数据到文件的特定位置。

扩展方法

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

参见