Used within SubSonic to automatically manage a SqlConnection. If a shared connection is available
for the specified provider on the current thread, that shared connection will be used.
Otherwise, a new connection will be created.
Note that if a shared connection is used, it will NOT be automatically disposed - that is up to the caller.
Lifetime management of the shared connection is taken care of by using a
SharedDbConnectionScope
If a new connection is created, it will be automatically dsiposed when this AutomaticConnectionScope object
is disposed.
Namespace:
SubSonic
Assembly:
SubSonic (in SubSonic.dll) Version: 2.1.0.0 (2.1.0)
Syntax
| Visual Basic (Declaration) |
|---|
Public Class AutomaticConnectionScope _
Implements IDisposable |
| Visual C++ |
|---|
public ref class AutomaticConnectionScope : IDisposable |
Inheritance Hierarchy
See Also