Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Net / System / Net / HttpListenerException.cs / 1305376 / HttpListenerException.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Net { using System; using System.ComponentModel; using System.Runtime.Serialization; using System.Runtime.InteropServices; [Serializable] public class HttpListenerException : Win32Exception { public HttpListenerException() : base(Marshal.GetLastWin32Error()) { GlobalLog.Print("HttpListenerException::.ctor() " + NativeErrorCode.ToString() + ":" + Message); } public HttpListenerException(int errorCode) : base(errorCode) { GlobalLog.Print("HttpListenerException::.ctor(int) " + NativeErrorCode.ToString() + ":" + Message); } public HttpListenerException(int errorCode, string message) : base(errorCode, message) { GlobalLog.Print("HttpListenerException::.ctor(int) " + NativeErrorCode.ToString() + ":" + Message); } protected HttpListenerException(SerializationInfo serializationInfo, StreamingContext streamingContext) : base(serializationInfo, streamingContext) { GlobalLog.Print("HttpListenerException::.ctor(serialized) " + NativeErrorCode.ToString() + ":" + Message); } public override int ErrorCode { // // the base class returns the HResult with this property // we need the Win32 Error Code, hence the override. // get { return NativeErrorCode; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Net { using System; using System.ComponentModel; using System.Runtime.Serialization; using System.Runtime.InteropServices; [Serializable] public class HttpListenerException : Win32Exception { public HttpListenerException() : base(Marshal.GetLastWin32Error()) { GlobalLog.Print("HttpListenerException::.ctor() " + NativeErrorCode.ToString() + ":" + Message); } public HttpListenerException(int errorCode) : base(errorCode) { GlobalLog.Print("HttpListenerException::.ctor(int) " + NativeErrorCode.ToString() + ":" + Message); } public HttpListenerException(int errorCode, string message) : base(errorCode, message) { GlobalLog.Print("HttpListenerException::.ctor(int) " + NativeErrorCode.ToString() + ":" + Message); } protected HttpListenerException(SerializationInfo serializationInfo, StreamingContext streamingContext) : base(serializationInfo, streamingContext) { GlobalLog.Print("HttpListenerException::.ctor(serialized) " + NativeErrorCode.ToString() + ":" + Message); } public override int ErrorCode { // // the base class returns the HResult with this property // we need the Win32 Error Code, hence the override. // get { return NativeErrorCode; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- BindValidator.cs
- XamlBrushSerializer.cs
- TextElementCollection.cs
- BitmapFrameEncode.cs
- PTConverter.cs
- SpoolingTask.cs
- RewritingValidator.cs
- FontUnitConverter.cs
- FormatConvertedBitmap.cs
- Typography.cs
- SecureConversationDriver.cs
- Listener.cs
- LoadMessageLogger.cs
- OracleConnectionString.cs
- CommandEventArgs.cs
- EventLogSession.cs
- DesignerLinkAdapter.cs
- Frame.cs
- BrushConverter.cs
- _RequestCacheProtocol.cs
- CachedTypeface.cs
- DataGridViewUtilities.cs
- NamedPipeActivation.cs
- GroupPartitionExpr.cs
- UmAlQuraCalendar.cs
- PopupControlService.cs
- DefaultEventAttribute.cs
- LogManagementAsyncResult.cs
- SqlServer2KCompatibilityAnnotation.cs
- QueryContinueDragEvent.cs
- EventProviderWriter.cs
- SafeThreadHandle.cs
- CompModSwitches.cs
- ListManagerBindingsCollection.cs
- UpdatePanelControlTrigger.cs
- AttachedAnnotation.cs
- DesignerPerfEventProvider.cs
- panel.cs
- PropertyGridEditorPart.cs
- BuildDependencySet.cs
- CodeExporter.cs
- SiteMapDataSource.cs
- XmlUtilWriter.cs
- DesignerForm.cs
- Transform3DCollection.cs
- List.cs
- SqlMethodTransformer.cs
- OleDbConnection.cs
- GlobalizationSection.cs
- GenericIdentity.cs
- HiddenField.cs
- State.cs
- OperandQuery.cs
- ReferentialConstraint.cs
- AndCondition.cs
- ProfileBuildProvider.cs
- PackageProperties.cs
- ContentElement.cs
- MachineSettingsSection.cs
- WebBrowsableAttribute.cs
- GlobalizationSection.cs
- SystemIcmpV4Statistics.cs
- CultureInfoConverter.cs
- RNGCryptoServiceProvider.cs
- WebBrowserNavigatingEventHandler.cs
- OdbcInfoMessageEvent.cs
- CodeSubDirectory.cs
- ListBoxDesigner.cs
- SqlGenerator.cs
- DbExpressionVisitor.cs
- Activity.cs
- WebEventCodes.cs
- Lease.cs
- Error.cs
- CustomError.cs
- WinHttpWebProxyFinder.cs
- CodeThrowExceptionStatement.cs
- StateRuntime.cs
- HttpWebResponse.cs
- UpdateCompiler.cs
- AppDomainManager.cs
- NamespaceQuery.cs
- ControlEvent.cs
- TextEditorCopyPaste.cs
- XmlSchemaSimpleType.cs
- EtwTrace.cs
- OperandQuery.cs
- RequestCachingSection.cs
- PersonalizationState.cs
- ConnectionPoint.cs
- WebPartManagerInternals.cs
- StringToken.cs
- SecurityRuntime.cs
- RootBuilder.cs
- Token.cs
- EmbeddedObject.cs
- ColumnResizeUndoUnit.cs
- ListViewSortEventArgs.cs
- XmlSchemaIdentityConstraint.cs
- TypeConverter.cs