CryptoStream.FlushFinalBlock 方法

定义

用缓冲区的当前状态更新基础数据源或存储库,随后清除缓冲区。Updates the underlying data source or repository with the current state of the buffer, then clears the buffer.

public:
 void FlushFinalBlock();
public void FlushFinalBlock ();
member this.FlushFinalBlock : unit -> unit
Public Sub FlushFinalBlock ()

异常

密钥已损坏,它可能会导致流的填充无效。The key is corrupt which can cause invalid padding to the stream.

当前流不可写。The current stream is not writable.

- 或 --or-

最后一个块已被转换。The final block has already been transformed.

注解

调用 Close 方法将调用 FlushFinalBlockCalling the Close method will call FlushFinalBlock. 如果未调用 Close,请调用 FlushFinalBlock 以完成刷新缓冲区。If you do not call Close, call FlushFinalBlock to complete flushing the buffer. 仅在所有流活动完成时调用 FlushFinalBlockCall FlushFinalBlock only when all stream activity is complete.

适用于

另请参阅