-
Notifications
You must be signed in to change notification settings - Fork 4
/
Transaction.vb
51 lines (39 loc) · 1.15 KB
/
Transaction.vb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
Imports System.Data.Common
Public MustInherit Class Transaction
Inherits DbTransaction
Public Overrides ReadOnly Property IsolationLevel As Data.IsolationLevel
Get
Return Me.Instance.IsolationLevel
End Get
End Property
Public Shadows ReadOnly Property Connection As DbConnection
Get
Return Me.ConnectionWrapper.Provider
End Get
End Property
Protected Overrides ReadOnly Property DbConnection As DbConnection
Get
Return Me.ConnectionWrapper.Provider
End Get
End Property
Public Overridable Property Instance As DbTransaction
Public Overridable Property ConnectionWrapper As Connection
Public Overrides Sub Commit()
Me.Instance.Commit()
End Sub
Public Shadows Function CreateObjRef(requestedType As Type)
Return Me.Instance.CreateObjRef(requestedType)
End Function
Public Shadows Sub Dispose()
Me.Instance.Dispose()
End Sub
Public Shadows Function GetLifetimeService()
Return Me.Instance.GetLifetimeService()
End Function
Public Overrides Function InitializeLifetimeService()
Return Me.Instance.InitializeLifetimeService()
End Function
Public Overrides Sub Rollback()
Me.Instance.Rollback()
End Sub
End Class