2008-10-31 Gonzalo Paniagua Javier <gonzalo@novell.com>
[mono.git] / mcs / class / System / System.Net / WebProxy.cs
index 91eef062a30b4842c2929183320c81a2440d0714..38ff3eb650a150d9f25899177c8e57319c195d7b 100644 (file)
@@ -142,6 +142,9 @@ namespace System.Net
 #endif
 
                // Methods
+#if NET_2_0
+               [Obsolete ("This method has been deprecated", false)]
+#endif
                [MonoTODO("Can we get this info under windows from the system?")]
                public static WebProxy GetDefaultProxy ()
                {
@@ -222,8 +225,10 @@ namespace System.Net
                        }
                }
 
-               void ISerializable.GetObjectData (SerializationInfo serializationInfo,
-                                                 StreamingContext streamingContext)
+#if NET_2_0
+               protected virtual 
+#endif
+               void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
                {
                        serializationInfo.AddValue ("_BypassOnLocal", bypassOnLocal);
                        serializationInfo.AddValue ("_ProxyAddress", address);
@@ -233,6 +238,12 @@ namespace System.Net
 #endif
                }
 
+               void ISerializable.GetObjectData (SerializationInfo serializationInfo,
+                                                 StreamingContext streamingContext)
+               {
+                       GetObjectData (serializationInfo, streamingContext);
+               }
+
                // Private Methods
                // this compiles the regular expressions, and will throw
                // an exception when an invalid one is found.