Explorar el Código

Update according to the new return type of
TdsConnectionPool.GetConnectionPool()

svn path=/trunk/mcs/; revision=105432

Veerapuram Varadhan hace 17 años
padre
commit
33b4b7433b

+ 5 - 0
mcs/class/System.Data/System.Data.SqlClient/ChangeLog

@@ -1,3 +1,8 @@
+2008-06-10  Veerapuram Varadhan  <[email protected]>
+	
+	* SqlConnection.cs: TdsConnectionPool.GetConnectionPool() now returns 
+	IDictionary<TKey, TValue>. 
+	
 2008-06-09  Ankit Jain  <[email protected]>
 
 	* SqlCommand.cs: Use Tds instead of ITds now.

+ 7 - 0
mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs

@@ -51,6 +51,9 @@ using System.Net;
 using System.Net.Sockets;
 using System.Text;
 using System.Xml;
+#if NET_2_0
+using System.Collections.Generic;
+#endif
 
 namespace System.Data.SqlClient
 {
@@ -1699,7 +1702,11 @@ namespace System.Data.SqlClient
 
 		public static void ClearAllPools ()
 		{
+#if NET_2_0
+			IDictionary <string, TdsConnectionPool> pools = SqlConnection.sqlConnectionPools.GetConnectionPool ();
+#else
 			Hashtable pools = SqlConnection.sqlConnectionPools.GetConnectionPool ();
+#endif
 			foreach (TdsConnectionPool pool in pools.Values) {
 				if (pool != null) {
 					pool.ResetConnectionPool ();