AdoDotNetConnectionSupport 類別
使用 ADO.NETIDbConnection, IDbCommand和 IDbTransaction介面,以提供 DataConnectionSupport、 DataCommand和 DataTransaction 類別的 Managed 實作,分別;也提供簡單的方式來提供 DataSourceVersionComparer類別的實作。
繼承階層架構
Object
Microsoft.VisualStudio.Data.ServiceProvider
Microsoft.VisualStudio.Data.ServiceProviderWithSite
Microsoft.VisualStudio.Data.DataConnectionSupport
Microsoft.VisualStudio.Data.AdoDotNet.AdoDotNetConnectionSupport
命名空間: Microsoft.VisualStudio.Data.AdoDotNet
組件: Microsoft.VisualStudio.Data (在 Microsoft.VisualStudio.Data.dll 中)
語法
'宣告
Public Class AdoDotNetConnectionSupport _
Inherits DataConnectionSupport
public class AdoDotNetConnectionSupport : DataConnectionSupport
public ref class AdoDotNetConnectionSupport : public DataConnectionSupport
type AdoDotNetConnectionSupport =
class
inherit DataConnectionSupport
end
public class AdoDotNetConnectionSupport extends DataConnectionSupport
AdoDotNetConnectionSupport 類型會公開下列成員。
建構函式
名稱 | 描述 | |
---|---|---|
![]() |
AdoDotNetConnectionSupport | 類別建構函式。初始化 AdoDotNetConnectionSupport 類別的執行個體具有指定的 ADO.NET 提供者名稱。 |
回頁首
屬性
名稱 | 描述 | |
---|---|---|
![]() |
BaseCommand | 擷取為執行於這個連接的命令使用的主要 IDbCommand 物件。 |
![]() |
Connection | 擷取目前連接支援執行個體所使用的 IDbConnection 物件。 |
![]() |
ConnectionString | 擷取或設定資訊的字串表示所要求之建立指定資料來源的連接。 (覆寫 DataConnectionSupport.ConnectionString。) |
![]() |
ConnectionTimeout | 以秒為單位擷取或設定時間,等候,在終止嘗試並產生錯誤逾時之前先建立連接。 (覆寫 DataConnectionSupport.ConnectionTimeout。) |
![]() |
CurrentTransactionLevel | 擷取目前的交易層級。 |
![]() |
ExecutingCommand | 擷取針對執行目前使用的 IDbCommand 執行個體。 |
![]() |
PreparedCommands | 擷取先前已準備好的 IDbCommand 物件清單。 |
![]() |
ProviderObject | 擷取指定之連接的基礎提供者物件。 (覆寫 DataConnectionSupport.ProviderObject。) |
![]() |
ServiceTypes | 擷取用於將服務型別清單轉換為 Unmanaged QueryService 方法呼叫之後,服務 GUID 指定,進入 Managed IServiceProvider.GetService 方法呼叫,指定 Managed 型別。 (繼承自 ServiceProvider)。 |
![]() |
Site | 擷取或設定站台物件執行個體。 (繼承自 ServiceProviderWithSite)。 |
![]() |
State | 擷取資料的連接狀態。 (覆寫 DataConnectionSupport.State。) |
![]() |
Transaction | 擷取目前 IDbTransaction,,如果有的話。 |
回頁首
方法
回頁首
事件
名稱 | 描述 | |
---|---|---|
![]() |
SiteChanged | 引發的,則 Site 屬性變更事件。 (繼承自 ServiceProviderWithSite)。 |
回頁首
明確介面實作
名稱 | 描述 | |
---|---|---|
![]() ![]() |
IObjectWithSite.GetSite | 擷取 IObjectWithSite.SetSite 使用方法設定的最後一個網站。如果沒有已知的網站,就會擲回例外狀況。 (繼承自 ServiceProviderWithSite)。 |
![]() ![]() |
IServiceProvider.QueryService | 執行做為傳遞的 IServiceProvider 實作公開服務的 Factory。 (繼承自 ServiceProvider)。 |
![]() ![]() |
IObjectWithSite.SetSite | 提供網站的 IUnknown 指標的特定物件。 (繼承自 ServiceProviderWithSite)。 |
回頁首
備註
這個類別會提供完整,依預設會針對 ADO.NET 資料提供者建立的 Managed 實作。
執行緒安全
這個類型的任何 Public static (在 Visual Basic 中為 Shared) 成員都是安全執行緒。不保證任何執行個體成員是安全執行緒。