System.Net.GlobalLog.LeaveException C# (CSharp) Method

LeaveException() private method

private LeaveException ( string func, Exception exception ) : void
func string
exception Exception
return void
        public static void LeaveException(string func, Exception exception) {
        }

Usage Example

Beispiel #1
0
        //
        // this method runs in the context of the user Begin call .
        //
        private static void WrappedGetRequestStreamCallback(object state)
        {
            GlobalLog.Enter("FileWebRequest::GetRequestStreamCallback");
            ContextAwareResult asyncResult = (ContextAwareResult)state;
            FileWebRequest     request     = (FileWebRequest)asyncResult.AsyncObject;

            try
            {
                if (request.m_stream == null)
                {
                    request.m_stream     = new FileWebStream(request, request.m_uri.LocalPath, FileMode.Create, FileAccess.Write, FileShare.Read);
                    request.m_fileAccess = FileAccess.Write;
                    request.m_writing    = true;
                    asyncResult.InvokeCallback(request.m_stream);
                    GlobalLog.Leave("FileWebRequest::GetRequestStreamCallback");
                }
            }
            catch (Exception e)
            {
                if (asyncResult.IsCompleted || NclUtilities.IsFatal(e))
                {
                    throw;
                }

                Exception ex = new WebException(e.Message, e);
                GlobalLog.LeaveException("FileWebRequest::GetRequestStreamCallback", ex);
                asyncResult.InvokeCallback(ex);
            }
        }
All Usage Examples Of System.Net.GlobalLog::LeaveException