共用方式為


CryptoStream 建構函式

定義

多載

CryptoStream(Stream, ICryptoTransform, CryptoStreamMode)

使用目標資料流、要使用的轉換與資料流的模式來初始化新的 CryptoStream 類別。

CryptoStream(Stream, ICryptoTransform, CryptoStreamMode, Boolean)

初始化 CryptoStream 類別的新執行個體。

CryptoStream(Stream, ICryptoTransform, CryptoStreamMode)

來源:
CryptoStream.cs
來源:
CryptoStream.cs
來源:
CryptoStream.cs

使用目標資料流、要使用的轉換與資料流的模式來初始化新的 CryptoStream 類別。

public:
 CryptoStream(System::IO::Stream ^ stream, System::Security::Cryptography::ICryptoTransform ^ transform, System::Security::Cryptography::CryptoStreamMode mode);
public CryptoStream (System.IO.Stream stream, System.Security.Cryptography.ICryptoTransform transform, System.Security.Cryptography.CryptoStreamMode mode);
new System.Security.Cryptography.CryptoStream : System.IO.Stream * System.Security.Cryptography.ICryptoTransform * System.Security.Cryptography.CryptoStreamMode -> System.Security.Cryptography.CryptoStream
Public Sub New (stream As Stream, transform As ICryptoTransform, mode As CryptoStreamMode)

參數

stream
Stream

要在其上執行密碼編譯轉換的資料流。

transform
ICryptoTransform

要在資料流上執行的密碼編譯轉換。

mode
CryptoStreamMode

其中一個 CryptoStreamMode 值。

例外狀況

stream 無效。

備註

任何衍生自 Stream 的物件都可以傳遞至 stream 參數。 任何實作 ICryptoTransform (的物件,例如 HashAlgorithm) 都可以傳遞至 transform 參數。

另請參閱

適用於

CryptoStream(Stream, ICryptoTransform, CryptoStreamMode, Boolean)

來源:
CryptoStream.cs
來源:
CryptoStream.cs
來源:
CryptoStream.cs

初始化 CryptoStream 類別的新執行個體。

public:
 CryptoStream(System::IO::Stream ^ stream, System::Security::Cryptography::ICryptoTransform ^ transform, System::Security::Cryptography::CryptoStreamMode mode, bool leaveOpen);
public CryptoStream (System.IO.Stream stream, System.Security.Cryptography.ICryptoTransform transform, System.Security.Cryptography.CryptoStreamMode mode, bool leaveOpen);
new System.Security.Cryptography.CryptoStream : System.IO.Stream * System.Security.Cryptography.ICryptoTransform * System.Security.Cryptography.CryptoStreamMode * bool -> System.Security.Cryptography.CryptoStream
Public Sub New (stream As Stream, transform As ICryptoTransform, mode As CryptoStreamMode, leaveOpen As Boolean)

參數

stream
Stream

要在其上執行密碼編譯轉換的資料流。

transform
ICryptoTransform

要在資料流上執行的密碼編譯轉換。

mode
CryptoStreamMode

資料流的模式。

leaveOpen
Boolean

處置 CryptoStream 物件後,若不關閉基礎資料流,則為 true;否則為 false

例外狀況

mode 無效。

適用於