XsBufferedFileStream 方法 |
XsBufferedFileStream 类型公开以下成员。
名称 | 说明 | |
---|---|---|
Close | Closes 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. (重写 Close.) | |
Flush | Clears buffers for this stream and causes any buffered data to be written to the file. (继承自 XsFileStream。) | |
Flush(Boolean) | Clears buffers for this stream and causes any buffered data to be written to the file, and also clears all intermediate file buffers. (重写 Flush(Boolean).) | |
Lock | Prevents other processes from reading from or writing to the FileStream. (继承自 XsFileStream。) | |
Read | Reads a block of bytes from the stream and writes the data in a given buffer. (重写 Read(Byte, Int32, Int32).) | |
Seek | Sets the current position of this stream to the given value. (重写 Seek(Int64, SeekOrigin).) | |
SetLength | Sets the length of this stream to the given value. (重写 SetLength(Int64).) | |
Unlock | Allows access by other processes to all or part of a file that was previously locked. (继承自 XsFileStream。) | |
Write | Writes a block of bytes to the file stream. (重写 Write(Byte, Int32, Int32).) | |
WriteByte | Writes a byte to the current position in the file stream. (重写 WriteByte(Byte).) | |
XRead | Bypass the buffered Read mechanism and call the original Read() method in the base class | |
XWrite | Bypass the buffered Write mechanism and call the original Write() method in the base class |
名称 | 说明 | |
---|---|---|
SafeLock | Locks a region in a stream. Contains TRY CATCH mechanism. (由 FileStreamExensions 定义。) | |
SafeRead(Byte) | 已重载。 Read data from a stream. Assumes that the whole buffer must be read. Reads from current location. (由 FileStreamExensions 定义。) | |
SafeRead(Byte, Int32) | 已重载。 Read data from a stream. Contains TRY CATCH mechanism. Reads from current location. (由 FileStreamExensions 定义。) | |
SafeRead(Byte, Int32, Int32) | 已重载。 Read data from a stream. Contains TRY CATCH mechanism. Reads from current location. (由 FileStreamExensions 定义。) | |
SafeReadAt(Int64, Byte) | 已重载。 Read data at a location in the file. Makes sure that file locations are >= 0. Assumes whole buffer must be read. (由 FileStreamExensions 定义。) | |
SafeReadAt(Int64, Byte, Int32) | 已重载。 Read data at a location in the file. Makes sure that file locations are >= 0 (由 FileStreamExensions 定义。) | |
SafeSetLength | Sets the length of a stream. Contains TRY CATCH mechanism. (由 FileStreamExensions 定义。) | |
SafeSetPos | Sets the location of a stream. Contains TRY CATCH mechanism. . (由 FileStreamExensions 定义。) | |
SafeUnlock | Unlocks a region in a stream. Contains TRY CATCH mechanism. (由 FileStreamExensions 定义。) | |
SafeWrite(Byte) | 已重载。 Write data to a stream. Contains TRY CATCH mechanism. Writes to the current location. Assumes the whole buffer must be written. (由 FileStreamExensions 定义。) | |
SafeWrite(Byte, Int32) | 已重载。 Write data to a stream. Contains TRY CATCH mechanism. Writes to the current location. (由 FileStreamExensions 定义。) | |
SafeWriteAt(Int64, Byte) | 已重载。 Write data at a location in the file. Makes sure that file locations are >= 0. Assumes whole buffer must be written. (由 FileStreamExensions 定义。) | |
SafeWriteAt(Int64, Byte, Int32) | 已重载。 Write data at a location in the file. Makes sure that file locations are >= 0. (由 FileStreamExensions 定义。) | |
SafeWriteByte | Write data to a stream. Contains TRY CATCH mechanism. Writes to the current location. (由 FileStreamExensions 定义。) |