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
- Color.cs
- EmptyCollection.cs
- MethodBody.cs
- KeySpline.cs
- Floater.cs
- WebPartEventArgs.cs
- EventLogWatcher.cs
- VisualBasicExpressionConverter.cs
- SourceItem.cs
- ValidatorCollection.cs
- XmlDictionaryReader.cs
- ProvidePropertyAttribute.cs
- SafeFileHandle.cs
- ProfileWorkflowElement.cs
- __ComObject.cs
- StartFileNameEditor.cs
- CalloutQueueItem.cs
- PropertyStore.cs
- TabletDevice.cs
- PropertyDescriptorComparer.cs
- SystemIPGlobalProperties.cs
- StreamSecurityUpgradeAcceptorBase.cs
- MsmqOutputMessage.cs
- LayoutTableCell.cs
- BitmapEffectrendercontext.cs
- EditorBrowsableAttribute.cs
- CodeObject.cs
- WebRequestModuleElement.cs
- ImportRequest.cs
- AttributeUsageAttribute.cs
- RuntimeConfig.cs
- SystemWebCachingSectionGroup.cs
- DataContract.cs
- PreProcessInputEventArgs.cs
- DbDeleteCommandTree.cs
- UnsafeNativeMethods.cs
- ProfileInfo.cs
- IssuanceTokenProviderBase.cs
- CqlWriter.cs
- GeometryModel3D.cs
- ContentValidator.cs
- RoleExceptions.cs
- GACMembershipCondition.cs
- OutputCacheModule.cs
- grammarelement.cs
- RectangleF.cs
- TextUtf8RawTextWriter.cs
- TablePatternIdentifiers.cs
- ErrorsHelper.cs
- SendKeys.cs
- Graph.cs
- Hashtable.cs
- PropertyPushdownHelper.cs
- VirtualPath.cs
- ForeignConstraint.cs
- ClientSettings.cs
- GlobalizationSection.cs
- ArrayWithOffset.cs
- DSASignatureFormatter.cs
- RegistrySecurity.cs
- ProfessionalColorTable.cs
- AnyReturnReader.cs
- ManagedWndProcTracker.cs
- AffineTransform3D.cs
- SelectionChangedEventArgs.cs
- Transform3D.cs
- HashMembershipCondition.cs
- TokenBasedSetEnumerator.cs
- MenuRenderer.cs
- HelpInfo.cs
- ToggleProviderWrapper.cs
- BoundsDrawingContextWalker.cs
- EditorReuseAttribute.cs
- ElementHostAutomationPeer.cs
- ServicePointManagerElement.cs
- RtfNavigator.cs
- DocumentEventArgs.cs
- RouteValueDictionary.cs
- LongValidatorAttribute.cs
- CursorInteropHelper.cs
- DecoderNLS.cs
- UniqueIdentifierService.cs
- Globals.cs
- X509UI.cs
- TextFormatter.cs
- XmlSubtreeReader.cs
- RubberbandSelector.cs
- CacheChildrenQuery.cs
- LayoutTable.cs
- SoapFormatter.cs
- VersionedStream.cs
- figurelengthconverter.cs
- SafeCoTaskMem.cs
- SHA1Managed.cs
- InputScope.cs
- Invariant.cs
- WSSecureConversation.cs
- SimpleWebHandlerParser.cs
- DocumentOrderQuery.cs
- NumberAction.cs