Hello!
I wrote this little constructor for the serialization support.
Can someone review it?, please.
I'd like to receive some feedback. 

Thanks in advance.
Best regards mono:: team. 


Cesar
Index: Hashtable.cs
===================================================================
RCS file: /mono/mcs/class/corlib/System.Collections/Hashtable.cs,v
retrieving revision 1.14
diff -u -r1.14 Hashtable.cs
--- Hashtable.cs        28 Apr 2002 19:42:42 -0000      1.14
+++ Hashtable.cs        9 Aug 2002 03:43:04 -0000
@@ -181,15 +181,15 @@
                {
                }
 
-               [MonoTODO]
                protected Hashtable (SerializationInfo info, StreamingContext context)
-               {
-//                     loadFactor = info.GetValue ("LoadFactor", Type.GetType 
("System.Float"));
-//                     comparerRef = info.GetValue ("Comparer", typeof (object));
-//                     hcpRef = info.GetValue ("HashCodeProvider", typeof (object));
-//                     this.Count = info.GetValue ("HashSize");
-//                     this.Keys = info.GetValue ("Keys");
-//                     this.Values = info.GetValue ("Values");
+               {                       
+                       loadFactor = info.GetSingle ("LoadFactor");                    
+ 
+                       this.modificationCount = info.GetInt32 ("Version");
+                       comparerRef = info.GetValue ("Comparer", typeof (IComparer));
+                       hcpRef = info.GetValue ("HashCodeProvider", typeof 
+(IHashCodeProvider));
+                       this.Count = info.GetInt32 ("HashSize");                       
+ 
+                       this.Keys = info.GetValue ("Keys", typeof (ICollection));
+                       this.Values = info.GetValue ("Values", typeof (ICollection));
                }
 
                //
@@ -407,7 +407,6 @@
                        return ht;
                }
 
-               [MonoTODO]
                public virtual void GetObjectData (SerializationInfo info, 
StreamingContext context)
                {
                        info.AddValue ("LoadFactor", loadFactor);
@@ -420,10 +419,10 @@
                }
 
                [MonoTODO]
-               public virtual void OnDeserialization (object sender)
-               {
-                       throw new NotImplementedException ();
-               }
+               public virtual void OnDeserialization (object sender)
+               {
+                       throw new NotImplementedException ();
+               }
 
                /// <summary>
                ///  Returns a synchronized (thread-safe)

Reply via email to