[System] Rename method parameters to match .NET contract
authorAlexander Köplinger <alex.koeplinger@outlook.com>
Wed, 15 Mar 2017 16:21:07 +0000 (17:21 +0100)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Thu, 16 Mar 2017 12:02:09 +0000 (13:02 +0100)
19 files changed:
mcs/class/System/System.Configuration/ConfigXmlDocument.cs
mcs/class/System/System.Configuration/SettingElement.cs
mcs/class/System/System.Configuration/SpecialSettingAttribute.cs
mcs/class/System/System.Diagnostics/CounterSample.cs
mcs/class/System/System.Diagnostics/EventLogEntryCollection.cs
mcs/class/System/System.Diagnostics/EventLogTraceListener.cs
mcs/class/System/System.Diagnostics/Process.cs
mcs/class/System/System.IO.Compression/DeflateStream.cs
mcs/class/System/System.IO.Ports/SerialPort.cs
mcs/class/System/System.Net.Mail/AlternateView.cs
mcs/class/System/System.Net.Mail/MailAddress.cs
mcs/class/System/System.Net.Mail/SmtpClient.cs
mcs/class/System/System.Net.Mail/SmtpException.cs
mcs/class/System/System.Net.Mail/SmtpFailedRecipientException.cs
mcs/class/System/System.Net.Mail/SmtpFailedRecipientsException.cs
mcs/class/System/System.Net.Sockets/Socket.cs
mcs/class/System/System.Net/HttpWebRequest.cs
mcs/class/System/System.Security.Permissions/StorePermission.cs
mcs/class/System/Test/System.Net.Mail/SmtpExceptionTest.cs

index c6ec61f1af60067e9072385ad0d2f13720d2f9a7..8f66d022a818cdec9e05741f0ccac99c72bb67c5 100644 (file)
@@ -63,9 +63,9 @@ namespace System.Configuration
                        return new ConfigXmlCDataSection (this, data);
                }
 
-               public override XmlComment CreateComment (string comment)
+               public override XmlComment CreateComment (string data)
                {
-                       return new ConfigXmlComment (this, comment);
+                       return new ConfigXmlComment (this, data);
                }
 
                public override XmlElement CreateElement (string prefix, string localName, string namespaceUri)
index 2a711689493251c6ee6350c3534782e8a33a9db8..b4ea085301ebba81ecbd8cbdeb79277bc4e6031c 100644 (file)
@@ -93,9 +93,9 @@ namespace System.Configuration
                        get { return properties; }
                }
 
-               public override bool Equals (object o)
+               public override bool Equals (object settings)
                {
-                       SettingElement e = o as SettingElement;
+                       SettingElement e = settings as SettingElement;
                        if (e == null)
                                return false;
 
index b47afa3cc43f35d3610ec697aa5eaa598487d202..e8a20f502a2875f1648d9248c31de07ac4355990 100644 (file)
@@ -35,9 +35,9 @@ namespace System.Configuration
        {
                SpecialSetting setting;
 
-               public SpecialSettingAttribute (SpecialSetting setting)
+               public SpecialSettingAttribute (SpecialSetting specialSetting)
                {
-                       this.setting = setting;
+                       this.setting = specialSetting;
                }
 
                public SpecialSetting SpecialSetting {
index 64ecf29d541ebf3f43b2b10cfaba008506762b37..82132de9959fbde07ed4c9a0be92d50b2969620a 100644 (file)
@@ -125,34 +125,34 @@ namespace System.Diagnostics {
                        return CounterSampleCalculator.ComputeCounterValue (counterSample, nextCounterSample);
                }
 
-               public override bool Equals (object obj)
+               public override bool Equals (object o)
                {
-                       if (!(obj is CounterSample))
+                       if (!(o is CounterSample))
                                return false;
-                       return Equals ((CounterSample) obj);
+                       return Equals ((CounterSample) o);
                }
 
-               public bool Equals (CounterSample other)
+               public bool Equals (CounterSample sample)
                {
                        return
-                               rawValue == other.rawValue &&
-                               baseValue == other.counterFrequency &&
-                               counterFrequency == other.counterFrequency &&
-                               systemFrequency == other.systemFrequency &&
-                               timeStamp == other.timeStamp &&
-                               timeStamp100nSec == other.timeStamp100nSec &&
-                               counterTimeStamp == other.counterTimeStamp &&
-                               counterType == other.counterType;
+                               rawValue == sample.rawValue &&
+                               baseValue == sample.counterFrequency &&
+                               counterFrequency == sample.counterFrequency &&
+                               systemFrequency == sample.systemFrequency &&
+                               timeStamp == sample.timeStamp &&
+                               timeStamp100nSec == sample.timeStamp100nSec &&
+                               counterTimeStamp == sample.counterTimeStamp &&
+                               counterType == sample.counterType;
                }
 
-               public static bool operator == (CounterSample obj1, CounterSample obj2)
+               public static bool operator == (CounterSample a, CounterSample b)
                {
-                       return obj1.Equals (obj2);
+                       return a.Equals (b);
                }
 
-               public static bool operator != (CounterSample obj1, CounterSample obj2)
+               public static bool operator != (CounterSample a, CounterSample b)
                {
-                       return !obj1.Equals (obj2);
+                       return !a.Equals (b);
                }
 
                public override int GetHashCode ()
index e083485d7bfa042737e1c2ca10f37791df99e73b..70cb0df4fcdb5f049e7b1d9f8749f71db0f2e053 100644 (file)
@@ -60,10 +60,10 @@ namespace System.Diagnostics {
                        get { return this; }
                }
 
-               public void CopyTo (EventLogEntry[] eventLogEntries, int index)
+               public void CopyTo (EventLogEntry[] entries, int index)
                {
                        EventLogEntry[] evLogEntries = _impl.GetEntries ();
-                       Array.Copy (evLogEntries, 0, eventLogEntries, index, evLogEntries.Length);
+                       Array.Copy (evLogEntries, 0, entries, index, evLogEntries.Length);
                }
 
                public IEnumerator GetEnumerator ()
index d7eeb0469776cd84328dcb5235459ed9402a68f6..46dad17505ba9fba58a28e08d303f562ff2212bf 100644 (file)
@@ -95,11 +95,11 @@ namespace System.Diagnostics
 
                [ComVisible (false)]
                public override void TraceData (TraceEventCache eventCache,
-                                               string source, TraceEventType eventType,
+                                               string source, TraceEventType severity,
                                                int id, object data)
                {
                        EventLogEntryType type;
-                       switch (eventType) {
+                       switch (severity) {
                        case TraceEventType.Critical:
                        case TraceEventType.Error:
                                type = EventLogEntryType.Error;
@@ -116,7 +116,7 @@ namespace System.Diagnostics
 
                [ComVisible (false)]
                public override void TraceData (TraceEventCache eventCache,
-                                               string source, TraceEventType eventType,
+                                               string source, TraceEventType severity,
                                                int id, params object [] data)
                {
                        string s = String.Empty;
@@ -126,23 +126,23 @@ namespace System.Diagnostics
                                        arr [i] = data [i] != null ? data [i].ToString () : String.Empty;
                                s = String.Join (", ", arr);
                        }
-                       TraceData (eventCache, source, eventType, id, s);
+                       TraceData (eventCache, source, severity, id, s);
                }
 
                [ComVisible (false)]
                public override void TraceEvent (TraceEventCache eventCache,
-                                                string source, TraceEventType eventType,
+                                                string source, TraceEventType severity,
                                                 int id, string message)
                {
-                       TraceData (eventCache, source, eventType, id, message);
+                       TraceData (eventCache, source, severity, id, message);
                }
 
                [ComVisible (false)]
                public override void TraceEvent (TraceEventCache eventCache,
-                                                string source, TraceEventType eventType,
+                                                string source, TraceEventType severity,
                                                 int id, string format, params object [] args)
                {
-                       TraceEvent (eventCache, source, eventType, id, format != null ? String.Format (format, args) : null);
+                       TraceEvent (eventCache, source, severity, id, format != null ? String.Format (format, args) : null);
                }
        }
 }
index 9b3fdf9dc5e26a631378240e3aba9405896f8dbd..59544083c38a96a0a74dbbf4769910302b163f83 100644 (file)
@@ -849,13 +849,13 @@ namespace System.Diagnostics
                }
 
                [Obsolete ("Process.Start is not supported on the current platform.", true)]
-               public static Process Start(string fileName, string username, SecureString password, string domain)
+               public static Process Start(string fileName, string userName, SecureString password, string domain)
                {
                        throw new PlatformNotSupportedException ("Process.Start is not supported on the current platform.");
                }
 
                [Obsolete ("Process.Start is not supported on the current platform.", true)]
-               public static Process Start(string fileName, string arguments, string username, SecureString password, string domain)
+               public static Process Start(string fileName, string arguments, string userName, SecureString password, string domain)
                {
                        throw new PlatformNotSupportedException ("Process.Start is not supported on the current platform.");
                }
index 4c41dbdf2e7ea58c0f6de168032ba6525427280f..9d8dd61eb2415641247d742c0cc3f77c7130ed3f 100644 (file)
@@ -193,8 +193,8 @@ namespace System.IO.Compression
                        }
                }
 
-               public override IAsyncResult BeginRead (byte [] buffer, int offset, int count,
-                                                       AsyncCallback cback, object state)
+               public override IAsyncResult BeginRead (byte [] array, int offset, int count,
+                                                       AsyncCallback asyncCallback, object asyncState)
                {
                        if (disposed)
                                throw new ObjectDisposedException (GetType ().FullName);
@@ -202,8 +202,8 @@ namespace System.IO.Compression
                        if (!CanRead)
                                throw new NotSupportedException ("This stream does not support reading");
 
-                       if (buffer == null)
-                               throw new ArgumentNullException ("buffer");
+                       if (array == null)
+                               throw new ArgumentNullException ("array");
 
                        if (count < 0)
                                throw new ArgumentOutOfRangeException ("count", "Must be >= 0");
@@ -211,15 +211,15 @@ namespace System.IO.Compression
                        if (offset < 0)
                                throw new ArgumentOutOfRangeException ("offset", "Must be >= 0");
 
-                       if (count + offset > buffer.Length)
+                       if (count + offset > array.Length)
                                throw new ArgumentException ("Buffer too small. count/offset wrong.");
 
                        ReadMethod r = new ReadMethod (ReadInternal);
-                       return r.BeginInvoke (buffer, offset, count, cback, state);
+                       return r.BeginInvoke (array, offset, count, asyncCallback, asyncState);
                }
 
-               public override IAsyncResult BeginWrite (byte [] buffer, int offset, int count,
-                                                       AsyncCallback cback, object state)
+               public override IAsyncResult BeginWrite (byte [] array, int offset, int count,
+                                                       AsyncCallback asyncCallback, object asyncState)
                {
                        if (disposed)
                                throw new ObjectDisposedException (GetType ().FullName);
@@ -227,8 +227,8 @@ namespace System.IO.Compression
                        if (!CanWrite)
                                throw new InvalidOperationException ("This stream does not support writing");
 
-                       if (buffer == null)
-                               throw new ArgumentNullException ("buffer");
+                       if (array == null)
+                               throw new ArgumentNullException ("array");
 
                        if (count < 0)
                                throw new ArgumentOutOfRangeException ("count", "Must be >= 0");
@@ -236,43 +236,43 @@ namespace System.IO.Compression
                        if (offset < 0)
                                throw new ArgumentOutOfRangeException ("offset", "Must be >= 0");
 
-                       if (count + offset > buffer.Length)
+                       if (count + offset > array.Length)
                                throw new ArgumentException ("Buffer too small. count/offset wrong.");
 
                        WriteMethod w = new WriteMethod (WriteInternal);
-                       return w.BeginInvoke (buffer, offset, count, cback, state);                     
+                       return w.BeginInvoke (array, offset, count, asyncCallback, asyncState);                 
                }
 
-               public override int EndRead(IAsyncResult async_result)
+               public override int EndRead(IAsyncResult asyncResult)
                {
-                       if (async_result == null)
-                               throw new ArgumentNullException ("async_result");
+                       if (asyncResult == null)
+                               throw new ArgumentNullException ("asyncResult");
 
-                       AsyncResult ares = async_result as AsyncResult;
+                       AsyncResult ares = asyncResult as AsyncResult;
                        if (ares == null)
-                               throw new ArgumentException ("Invalid IAsyncResult", "async_result");
+                               throw new ArgumentException ("Invalid IAsyncResult", "asyncResult");
 
                        ReadMethod r = ares.AsyncDelegate as ReadMethod;
                        if (r == null)
-                               throw new ArgumentException ("Invalid IAsyncResult", "async_result");
+                               throw new ArgumentException ("Invalid IAsyncResult", "asyncResult");
 
-                       return r.EndInvoke (async_result);
+                       return r.EndInvoke (asyncResult);
                }
 
-               public override void EndWrite (IAsyncResult async_result)
+               public override void EndWrite (IAsyncResult asyncResult)
                {
-                       if (async_result == null)
-                               throw new ArgumentNullException ("async_result");
+                       if (asyncResult == null)
+                               throw new ArgumentNullException ("asyncResult");
 
-                       AsyncResult ares = async_result as AsyncResult;
+                       AsyncResult ares = asyncResult as AsyncResult;
                        if (ares == null)
-                               throw new ArgumentException ("Invalid IAsyncResult", "async_result");
+                               throw new ArgumentException ("Invalid IAsyncResult", "asyncResult");
 
                        WriteMethod w = ares.AsyncDelegate as WriteMethod;
                        if (w == null)
-                               throw new ArgumentException ("Invalid IAsyncResult", "async_result");
+                               throw new ArgumentException ("Invalid IAsyncResult", "asyncResult");
 
-                       w.EndInvoke (async_result);
+                       w.EndInvoke (asyncResult);
                        return;
                }
 
index 65189c5813f986b05aeac8d71d7bdbd7ed6f5c8a..5fb9d624e855f31c9fcc5cebe307c36b4ad42202 100644 (file)
@@ -696,13 +696,13 @@ namespace System.IO.Ports
                        return encoding.GetString (seen.ToArray ());
                }
 
-               public void Write (string str)
+               public void Write (string text)
                {
                        CheckOpen ();
-                       if (str == null)
-                               throw new ArgumentNullException ("str");
+                       if (text == null)
+                               throw new ArgumentNullException ("text");
                        
-                       byte [] buffer = encoding.GetBytes (str);
+                       byte [] buffer = encoding.GetBytes (text);
                        Write (buffer, 0, buffer.Length);
                }
 
@@ -739,9 +739,9 @@ namespace System.IO.Ports
                        stream.Write (bytes, 0, bytes.Length);
                }
 
-               public void WriteLine (string str)
+               public void WriteLine (string text)
                {
-                       Write (str + new_line);
+                       Write (text + new_line);
                }
 
                void CheckOpen ()
index 2a84e67de361acc803f459bb1f975057bce62f72..df85b0f97c76379d3b012df5f52f7c7d1986faca 100644 (file)
@@ -111,16 +111,16 @@ namespace System.Net.Mail {
                        return av;
                }
 
-               public static AlternateView CreateAlternateViewFromString (string content, Encoding encoding, string mediaType)
+               public static AlternateView CreateAlternateViewFromString (string content, Encoding contentEncoding, string mediaType)
                {
                        if (content == null)
                                throw new ArgumentNullException ("content");
-                       if (encoding == null)
-                               encoding = Encoding.UTF8;
-                       MemoryStream ms = new MemoryStream (encoding.GetBytes (content));
+                       if (contentEncoding == null)
+                               contentEncoding = Encoding.UTF8;
+                       MemoryStream ms = new MemoryStream (contentEncoding.GetBytes (content));
                        ContentType ct = new ContentType ();
                        ct.MediaType = mediaType;
-                       ct.CharSet = encoding.HeaderName;
+                       ct.CharSet = contentEncoding.HeaderName;
                        AlternateView av = new AlternateView (ms, ct);
                        av.TransferEncoding = TransferEncoding.QuotedPrintable;
                        return av;
index 5ffaf6b4bd110ee2dac9486133082dba434a1783..ff342b3cd0f1746e4932a332923b67a016d945d0 100644 (file)
@@ -143,12 +143,12 @@ namespace System.Net.Mail {
 
 #region Methods
                
-               public override bool Equals (object obj)
+               public override bool Equals (object value)
                {
-                       if (obj == null)
+                       if (value == null)
                                return false;
 
-                       return (0 == String.Compare (ToString (), obj.ToString (), StringComparison.OrdinalIgnoreCase));
+                       return (0 == String.Compare (ToString (), value.ToString (), StringComparison.OrdinalIgnoreCase));
                }
 
                public override int GetHashCode ()
index ca658c23d752345e3bbd9f5e7f6fa6434ae1f7ca..19197681a7ed5caad5500a133ca6bfca22560474 100644 (file)
@@ -742,9 +742,9 @@ namespace System.Net.Mail {
                        }
                }
 
-               public void Send (string from, string to, string subject, string body)
+               public void Send (string from, string recipients, string subject, string body)
                {
-                       Send (new MailMessage (from, to, subject, body));
+                       Send (new MailMessage (from, recipients, subject, body));
                }
 
                public Task SendMailAsync (MailMessage message)
@@ -836,9 +836,9 @@ namespace System.Net.Mail {
                        worker.RunWorkerAsync (userToken);
                }
 
-               public void SendAsync (string from, string to, string subject, string body, object userToken)
+               public void SendAsync (string from, string recipients, string subject, string body, object userToken)
                {
-                       SendAsync (new MailMessage (from, to, subject, body), userToken);
+                       SendAsync (new MailMessage (from, recipients, subject, body), userToken);
                }
 
                public void SendAsyncCancel ()
index ceda2dd7b9caa132f07aaf9b3bf42742366c10b1..7dc3e94bc0a74829635a7144e1330ed530895370 100644 (file)
@@ -57,14 +57,14 @@ namespace System.Net.Mail {
                {
                }
 
-               protected SmtpException (SerializationInfo info, StreamingContext context)
-                       : base (info, context)
+               protected SmtpException (SerializationInfo serializationInfo, StreamingContext streamingContext)
+                       : base (serializationInfo, streamingContext)
                {
                        try {
-                               statusCode = (SmtpStatusCode) info.GetValue ("Status", typeof (int));
+                               statusCode = (SmtpStatusCode) serializationInfo.GetValue ("Status", typeof (int));
                        } catch (SerializationException) {
                                //For compliance with previously serialized version:
-                               statusCode = (SmtpStatusCode) info.GetValue ("statusCode", typeof (SmtpStatusCode));
+                               statusCode = (SmtpStatusCode) serializationInfo.GetValue ("statusCode", typeof (SmtpStatusCode));
                        }
                }
 
@@ -91,12 +91,12 @@ namespace System.Net.Mail {
 
                #endregion // Properties
 
-               public override void GetObjectData (SerializationInfo info, StreamingContext context)
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
                {
-                       if (info == null)
-                               throw new ArgumentNullException ("info");
-                       base.GetObjectData (info, context);
-                       info.AddValue ("Status", statusCode, typeof (int));
+                       if (serializationInfo == null)
+                               throw new ArgumentNullException ("serializationInfo");
+                       base.GetObjectData (serializationInfo, streamingContext);
+                       serializationInfo.AddValue ("Status", statusCode, typeof (int));
                }
                void ISerializable.GetObjectData (SerializationInfo info, StreamingContext context)
                {
index c4dbe9c03416f9904074d69539bdbdb77c6e4b8c..faff2db4dbf1772a8c6c2c1715cd3ffd0c292aa6 100644 (file)
@@ -52,12 +52,12 @@ namespace System.Net.Mail {
                {
                }
 
-               protected SmtpFailedRecipientException (SerializationInfo serializationInfo, StreamingContext streamingContext)
-                       : base (serializationInfo, streamingContext)
+               protected SmtpFailedRecipientException (SerializationInfo info, StreamingContext context)
+                       : base (info, context)
                {
-                       if (serializationInfo == null)
-                               throw new ArgumentNullException ("serializationInfo");
-                       failedRecipient = serializationInfo.GetString ("failedRecipient");
+                       if (info == null)
+                               throw new ArgumentNullException ("info");
+                       failedRecipient = info.GetString ("failedRecipient");
                }
 
                public SmtpFailedRecipientException (SmtpStatusCode statusCode, string failedRecipient) : base (statusCode)
index 6f2e3af8e50d808092b2836f09c10893d703c199..70ac1a324b2d08c37a2b00e2266cbac7c535811d 100644 (file)
@@ -80,12 +80,12 @@ namespace System.Net.Mail {
 
                #region Methods
 
-               public override void GetObjectData (SerializationInfo info, StreamingContext context)
+               public override void GetObjectData (SerializationInfo serializationInfo, StreamingContext streamingContext)
                {
-                       if (info == null)
-                               throw new ArgumentNullException ("info");
-                       base.GetObjectData (info, context);
-                       info.AddValue ("innerExceptions", innerExceptions);
+                       if (serializationInfo == null)
+                               throw new ArgumentNullException ("serializationInfo");
+                       base.GetObjectData (serializationInfo, streamingContext);
+                       serializationInfo.AddValue ("innerExceptions", innerExceptions);
                }
 
                void ISerializable.GetObjectData (SerializationInfo info, StreamingContext context)
index 91d43ad31617cb9019794b41eb6c1264747b01a6..e5d0536e06876efb440c7eedf3a070826fa5ccc5 100644 (file)
@@ -709,11 +709,11 @@ namespace System.Net.Sockets
                        sockares.Complete (acc_socket, total);
                });
 
-               public Socket EndAccept (IAsyncResult result)
+               public Socket EndAccept (IAsyncResult asyncResult)
                {
                        int bytes;
                        byte[] buffer;
-                       return EndAccept (out buffer, out bytes, result);
+                       return EndAccept (out buffer, out bytes, asyncResult);
                }
 
                public Socket EndAccept (out byte[] buffer, out int bytesTransferred, IAsyncResult asyncResult)
@@ -948,7 +948,7 @@ namespace System.Net.Sockets
                        }
                });
 
-               public IAsyncResult BeginConnect (string host, int port, AsyncCallback callback, object state)
+               public IAsyncResult BeginConnect (string host, int port, AsyncCallback requestCallback, object state)
                {
                        ThrowIfDisposedAndClosed ();
 
@@ -961,31 +961,31 @@ namespace System.Net.Sockets
                        if (is_listening)
                                throw new InvalidOperationException ();
 
-                       return BeginConnect (Dns.GetHostAddresses (host), port, callback, state);
+                       return BeginConnect (Dns.GetHostAddresses (host), port, requestCallback, state);
                }
 
-               public IAsyncResult BeginConnect (EndPoint end_point, AsyncCallback callback, object state)
+               public IAsyncResult BeginConnect (EndPoint remoteEP, AsyncCallback callback, object state)
                {
                        ThrowIfDisposedAndClosed ();
 
-                       if (end_point == null)
-                               throw new ArgumentNullException ("end_point");
+                       if (remoteEP == null)
+                               throw new ArgumentNullException ("remoteEP");
                        if (is_listening)
                                throw new InvalidOperationException ();
 
                        SocketAsyncResult sockares = new SocketAsyncResult (this, callback, state, SocketOperation.Connect) {
-                               EndPoint = end_point,
+                               EndPoint = remoteEP,
                        };
 
                        // Bug #75154: Connect() should not succeed for .Any addresses.
-                       if (end_point is IPEndPoint) {
-                               IPEndPoint ep = (IPEndPoint) end_point;
+                       if (remoteEP is IPEndPoint) {
+                               IPEndPoint ep = (IPEndPoint) remoteEP;
                                if (ep.Address.Equals (IPAddress.Any) || ep.Address.Equals (IPAddress.IPv6Any)) {
                                        sockares.Complete (new SocketException ((int) SocketError.AddressNotAvailable), true);
                                        return sockares;
                                }
                                
-                               end_point = RemapIPEndPoint (ep);
+                               remoteEP = RemapIPEndPoint (ep);
                        }
 
                        int error = 0;
@@ -1004,7 +1004,7 @@ namespace System.Net.Sockets
                        bool blk = is_blocking;
                        if (blk)
                                Blocking = false;
-                       Connect_internal (m_Handle, end_point.Serialize (), out error, false);
+                       Connect_internal (m_Handle, remoteEP.Serialize (), out error, false);
                        if (blk)
                                Blocking = true;
 
@@ -1034,7 +1034,7 @@ namespace System.Net.Sockets
                        return sockares;
                }
 
-               public IAsyncResult BeginConnect (IPAddress[] addresses, int port, AsyncCallback callback, object state)
+               public IAsyncResult BeginConnect (IPAddress[] addresses, int port, AsyncCallback requestCallback, object state)
                {
                        ThrowIfDisposedAndClosed ();
 
@@ -1049,7 +1049,7 @@ namespace System.Net.Sockets
                        if (is_listening)
                                throw new InvalidOperationException ();
 
-                       SocketAsyncResult sockares = new SocketAsyncResult (this, callback, state, SocketOperation.Connect) {
+                       SocketAsyncResult sockares = new SocketAsyncResult (this, requestCallback, state, SocketOperation.Connect) {
                                Addresses = addresses,
                                Port = port,
                        };
@@ -1142,11 +1142,11 @@ namespace System.Net.Sockets
                        }
                });
 
-               public void EndConnect (IAsyncResult result)
+               public void EndConnect (IAsyncResult asyncResult)
                {
                        ThrowIfDisposedAndClosed ();
 
-                       SocketAsyncResult sockares = ValidateEndIAsyncResult (result, "EndConnect", "result");
+                       SocketAsyncResult sockares = ValidateEndIAsyncResult (asyncResult, "EndConnect", "asyncResult");
 
                        if (!sockares.IsCompleted)
                                sockares.AsyncWaitHandle.WaitOne();
@@ -1629,21 +1629,21 @@ namespace System.Net.Sockets
                        }
                });
 
-               public IAsyncResult BeginReceiveFrom (byte[] buffer, int offset, int size, SocketFlags socket_flags, ref EndPoint remote_end, AsyncCallback callback, object state)
+               public IAsyncResult BeginReceiveFrom (byte[] buffer, int offset, int size, SocketFlags socketFlags, ref EndPoint remoteEP, AsyncCallback callback, object state)
                {
                        ThrowIfDisposedAndClosed ();
                        ThrowIfBufferNull (buffer);
                        ThrowIfBufferOutOfRange (buffer, offset, size);
 
-                       if (remote_end == null)
-                               throw new ArgumentNullException ("remote_end");
+                       if (remoteEP == null)
+                               throw new ArgumentNullException ("remoteEP");
 
                        SocketAsyncResult sockares = new SocketAsyncResult (this, callback, state, SocketOperation.ReceiveFrom) {
                                Buffer = buffer,
                                Offset = offset,
                                Size = size,
-                               SockFlags = socket_flags,
-                               EndPoint = remote_end,
+                               SockFlags = socketFlags,
+                               EndPoint = remoteEP,
                        };
 
                        QueueIOSelectorJob (ReadSem, sockares.Handle, new IOSelectorJob (IOOperation.Read, BeginReceiveFromCallback, sockares));
@@ -1671,21 +1671,21 @@ namespace System.Net.Sockets
                        sockares.Complete (total);
                });
 
-               public int EndReceiveFrom(IAsyncResult result, ref EndPoint end_point)
+               public int EndReceiveFrom(IAsyncResult asyncResult, ref EndPoint endPoint)
                {
                        ThrowIfDisposedAndClosed ();
 
-                       if (end_point == null)
-                               throw new ArgumentNullException ("remote_end");
+                       if (endPoint == null)
+                               throw new ArgumentNullException ("endPoint");
 
-                       SocketAsyncResult sockares = ValidateEndIAsyncResult (result, "EndReceiveFrom", "result");
+                       SocketAsyncResult sockares = ValidateEndIAsyncResult (asyncResult, "EndReceiveFrom", "asyncResult");
 
                        if (!sockares.IsCompleted)
                                sockares.AsyncWaitHandle.WaitOne();
 
                        sockares.CheckIfThrowDelayedException();
 
-                       end_point = sockares.EndPoint;
+                       endPoint = sockares.EndPoint;
 
                        return sockares.Total;
                }
@@ -2095,7 +2095,7 @@ m_Handle, buffer, offset + sent, size - sent, socketFlags, out nativeError, is_b
                        }
                });
 
-               public IAsyncResult BeginSendTo(byte[] buffer, int offset, int size, SocketFlags socket_flags, EndPoint remote_end, AsyncCallback callback, object state)
+               public IAsyncResult BeginSendTo(byte[] buffer, int offset, int size, SocketFlags socketFlags, EndPoint remoteEP, AsyncCallback callback, object state)
                {
                        ThrowIfDisposedAndClosed ();
                        ThrowIfBufferNull (buffer);
@@ -2105,8 +2105,8 @@ m_Handle, buffer, offset + sent, size - sent, socketFlags, out nativeError, is_b
                                Buffer = buffer,
                                Offset = offset,
                                Size = size,
-                               SockFlags = socket_flags,
-                               EndPoint = remote_end,
+                               SockFlags = socketFlags,
+                               EndPoint = remoteEP,
                        };
 
                        QueueIOSelectorJob (WriteSem, sockares.Handle, new IOSelectorJob (IOOperation.Write, s => BeginSendToCallback ((SocketAsyncResult) s, 0), sockares));
@@ -2140,11 +2140,11 @@ m_Handle, buffer, offset + sent, size - sent, socketFlags, out nativeError, is_b
                        sockares.Complete ();
                }
 
-               public int EndSendTo (IAsyncResult result)
+               public int EndSendTo (IAsyncResult asyncResult)
                {
                        ThrowIfDisposedAndClosed ();
 
-                       SocketAsyncResult sockares = ValidateEndIAsyncResult (result, "EndSendTo", "result");
+                       SocketAsyncResult sockares = ValidateEndIAsyncResult (asyncResult, "EndSendTo", "result");
 
                        if (!sockares.IsCompleted)
                                sockares.AsyncWaitHandle.WaitOne();
index a57c579250ed33e6f27cb11ad04469840f3a06b3..5ca0425eb5af4444e5868505ef30bdac53e1890d 100644 (file)
@@ -1031,9 +1031,9 @@ namespace System.Net
                        return result.Response;
                }
                
-               public Stream EndGetRequestStream (IAsyncResult asyncResult, out TransportContext transportContext)
+               public Stream EndGetRequestStream (IAsyncResult asyncResult, out TransportContext context)
                {
-                       transportContext = null;
+                       context = null;
                        return EndGetRequestStream (asyncResult);
                }
 
index 0debdb9b9b47d24041064d84868dbe94c90153b9..62ae915ca3b7fce7c748b192fa2367417df3e974 100644 (file)
@@ -46,10 +46,10 @@ namespace System.Security.Permissions {
                                _flags = StorePermissionFlags.NoFlags;
                }
 
-               public StorePermission (StorePermissionFlags flags
+               public StorePermission (StorePermissionFlags flag) 
                {
                        // reuse validation by the Flags property
-                       Flags = flags;
+                       Flags = flag;
                }
 
 
@@ -129,14 +129,14 @@ namespace System.Security.Permissions {
                        return ((_flags & ~dp._flags) == 0);
                }
 
-               public override void FromXml (SecurityElement e
+               public override void FromXml (SecurityElement securityElement
                {
                        // General validation in CodeAccessPermission
-                       PermissionHelper.CheckSecurityElement (e, "e", version, version);
+                       PermissionHelper.CheckSecurityElement (securityElement, "securityElement", version, version);
                        // Note: we do not (yet) care about the return value 
                        // as we only accept version 1 (min/max values)
 
-                       string s = e.Attribute ("Flags");
+                       string s = securityElement.Attribute ("Flags");
                        if (s == null)
                                _flags = StorePermissionFlags.NoFlags;
                        else
index 40c11663fab1e1fce0138446c343cc81a4d78519..64469915dff1cc72f5228125ee95f3d2a1bd3fc0 100644 (file)
@@ -302,14 +302,14 @@ namespace MonoTests.System.Net.Mail {
                                Assert.AreEqual (typeof (ArgumentNullException), ex.GetType (), "#2");
                                Assert.IsNull (ex.InnerException, "#3");
                                Assert.IsNotNull (ex.Message, "#4");
-                               Assert.AreEqual ("info", ex.ParamName, "#5");
+                               Assert.AreEqual ("serializationInfo", ex.ParamName, "#5");
                        }
                }
        }
 
        class MySmtpException : SmtpException {
-               public MySmtpException (SerializationInfo info, StreamingContext context)
-                       : base (info, context)
+               public MySmtpException (SerializationInfo serializationInfo, StreamingContext streamingContext)
+                       : base (serializationInfo, streamingContext)
                {
                }
        }