SqlAuthenticationParameters 建構函式

定義

多載

名稱 Description
SqlAuthenticationParameters(SqlAuthenticationMethod, String, String, String, String, String, String, Guid)

使用指定的認證方法、伺服器名稱、資料庫名稱、資源 URI、權威 URI、使用者登入名稱/ID、使用者密碼及連線 ID 初始化該類別的新 SqlAuthenticationParameters 實例。

SqlAuthenticationParameters(SqlAuthenticationMethod, String, String, String, String, String, String, Guid, Int32)

構造出所有屬性的值。

SqlAuthenticationParameters(SqlAuthenticationMethod, String, String, String, String, String, String, Guid)

使用指定的認證方法、伺服器名稱、資料庫名稱、資源 URI、權威 URI、使用者登入名稱/ID、使用者密碼及連線 ID 初始化該類別的新 SqlAuthenticationParameters 實例。

protected:
 SqlAuthenticationParameters(Microsoft::Data::SqlClient::SqlAuthenticationMethod authenticationMethod, System::String ^ serverName, System::String ^ databaseName, System::String ^ resource, System::String ^ authority, System::String ^ userId, System::String ^ password, Guid connectionId);
protected SqlAuthenticationParameters(Microsoft.Data.SqlClient.SqlAuthenticationMethod authenticationMethod, string serverName, string databaseName, string resource, string authority, string userId, string password, Guid connectionId);
new Microsoft.Data.SqlClient.SqlAuthenticationParameters : Microsoft.Data.SqlClient.SqlAuthenticationMethod * string * string * string * string * string * string * Guid -> Microsoft.Data.SqlClient.SqlAuthenticationParameters
Protected Sub New (authenticationMethod As SqlAuthenticationMethod, serverName As String, databaseName As String, resource As String, authority As String, userId As String, password As String, connectionId As Guid)

參數

authenticationMethod
SqlAuthenticationMethod

其中一個列舉值,用來指定認證方法。

serverName
String

伺服器名稱。

databaseName
String

資料庫名稱。

resource
String

資源是URI。

authority
String

URI 的管理局。

userId
String

使用者登入名稱/ID。

password
String

用戶密碼。

connectionId
Guid

連線ID。

適用於

SqlAuthenticationParameters(SqlAuthenticationMethod, String, String, String, String, String, String, Guid, Int32)

來源:
SqlAuthenticationParameters.cs
來源:
SqlAuthenticationParameters.cs
來源:
SqlAuthenticationParameters.cs

構造出所有屬性的值。

protected:
 SqlAuthenticationParameters(Microsoft::Data::SqlClient::SqlAuthenticationMethod authenticationMethod, System::String ^ serverName, System::String ^ databaseName, System::String ^ resource, System::String ^ authority, System::String ^ userId, System::String ^ password, Guid connectionId, int connectionTimeout);
public:
 SqlAuthenticationParameters(Microsoft::Data::SqlClient::SqlAuthenticationMethod authenticationMethod, System::String ^ serverName, System::String ^ databaseName, System::String ^ resource, System::String ^ authority, System::String ^ userId, System::String ^ password, Guid connectionId, int connectionTimeout);
protected SqlAuthenticationParameters(Microsoft.Data.SqlClient.SqlAuthenticationMethod authenticationMethod, string serverName, string databaseName, string resource, string authority, string userId, string password, Guid connectionId, int connectionTimeout);
public SqlAuthenticationParameters(Microsoft.Data.SqlClient.SqlAuthenticationMethod authenticationMethod, string serverName, string databaseName, string resource, string authority, string? userId, string? password, Guid connectionId, int connectionTimeout);
new Microsoft.Data.SqlClient.SqlAuthenticationParameters : Microsoft.Data.SqlClient.SqlAuthenticationMethod * string * string * string * string * string * string * Guid * int -> Microsoft.Data.SqlClient.SqlAuthenticationParameters
Protected Sub New (authenticationMethod As SqlAuthenticationMethod, serverName As String, databaseName As String, resource As String, authority As String, userId As String, password As String, connectionId As Guid, connectionTimeout As Integer)
Public Sub New (authenticationMethod As SqlAuthenticationMethod, serverName As String, databaseName As String, resource As String, authority As String, userId As String, password As String, connectionId As Guid, connectionTimeout As Integer)

參數

authenticationMethod
SqlAuthenticationMethod

驗證方法。

serverName
String

伺服器名稱。

databaseName
String

資料庫名稱。

resource
String

資源是URI。

authority
String

URI 的管理局。

userId
String

使用者登入名稱/ID,若不適用則為空。

password
String

使用者密碼,若不適用則為 null。

connectionId
Guid

連線ID。

connectionTimeout
Int32

認證逾時,幾秒鐘內完成。 整體連線逾時由驅動程式管理;此超時僅適用於認證。

適用於