Partager via


LobSystemInstance.CloseConnection, méthode (Microsoft.Office.Server.ApplicationRegistry.MetadataModel)

Closes the connection to the business application.

Espace de noms : Microsoft.Office.Server.ApplicationRegistry.MetadataModel
Assembly : Microsoft.SharePoint.Portal (dans microsoft.sharepoint.portal.dll)

Syntaxe

'Déclaration
Public Sub CloseConnection
'Utilisation
Dim instance As LobSystemInstance

instance.CloseConnection
public void CloseConnection ()

Remarques

Business Data clients can use two forms of connection management:

1. Explicit connection management

2. Implicit connection management

Explicit connection management is more complex but is useful and performant when sharing connections. For example, if three Business Data web parts want to share a connection to a backend and query it sequentially, implicit connection management would open and close a connection in each case. It is better to explicitly open a connection using LobSystemInstance.OpenConnection(), make the 3 Business Data Catalog object model calls from the 3 Business Data web parts and then close the connection. CloseConnection allows closing an explicitly opened connection.

Voir aussi

Référence

LobSystemInstance, classe
Membres LobSystemInstance
Microsoft.Office.Server.ApplicationRegistry.MetadataModel, espace de noms