Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Gets the current connection for a query.
Namespace: Microsoft.SqlServer.Management.XEvent
Assembly: Microsoft.SqlServer.Management.XEvent (in Microsoft.SqlServer.Management.XEvent.dll)
Syntax
'Declaration
Private Function GetConnection ( _
mode As SfcObjectQueryMode _
) As ISfcConnection Implements ISfcHasConnection.GetConnection
'Usage
Dim instance As XEStore
Dim mode As SfcObjectQueryMode
Dim returnValue As ISfcConnection
returnValue = CType(instance, ISfcHasConnection).GetConnection(mode)
ISfcConnection ISfcHasConnection.GetConnection(
SfcObjectQueryMode mode
)
private:
virtual ISfcConnection^ GetConnection(
SfcObjectQueryMode mode
) sealed = ISfcHasConnection::GetConnection
private abstract GetConnection :
mode:SfcObjectQueryMode -> ISfcConnection
private override GetConnection :
mode:SfcObjectQueryMode -> ISfcConnection
JScript supports the use of explicit interface implementations, but not the declarations of new ones.
Parameters
- mode
Type: Microsoft.SqlServer.Management.Sdk.Sfc.SfcObjectQueryMode
Specifies Microsoft.SqlServer.Management.Sdk.Sfc.SfcObjectQueryMode.
Return Value
Type: Microsoft.SqlServer.Management.Common.ISfcConnection
Returns the connection, or null, in which case cache mode connection is specified.
Implements
ISfcHasConnection.GetConnection(SfcObjectQueryMode)
Remarks
The method returns a connection supporting either a single serial query or multiple simultaneously open queries. Cache mode avoids connection and open data reader issues.