Code:
/ 4.0 / 4.0 / untmp / 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.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- BindingsCollection.cs
- PolyBezierSegment.cs
- DispatchChannelSink.cs
- LogPolicy.cs
- WorkflowMessageEventHandler.cs
- PageAsyncTask.cs
- StylusDownEventArgs.cs
- sqlinternaltransaction.cs
- ColumnReorderedEventArgs.cs
- ReachSerializerAsync.cs
- DependentTransaction.cs
- Stroke.cs
- FixedSOMImage.cs
- ProxyElement.cs
- Semaphore.cs
- ContextMenuService.cs
- GeneralTransform.cs
- StylusPointDescription.cs
- ThreadExceptionEvent.cs
- CharacterMetrics.cs
- DataColumnPropertyDescriptor.cs
- CapabilitiesSection.cs
- ResourceProviderFactory.cs
- mongolianshape.cs
- SqlDelegatedTransaction.cs
- DataServiceQueryException.cs
- InstanceDescriptor.cs
- RemotingException.cs
- PolicyException.cs
- Adorner.cs
- DocumentSequenceHighlightLayer.cs
- COM2IDispatchConverter.cs
- CultureMapper.cs
- URLIdentityPermission.cs
- Preprocessor.cs
- SBCSCodePageEncoding.cs
- XPathNodePointer.cs
- ClientTargetSection.cs
- Encoder.cs
- CmsInterop.cs
- PanelStyle.cs
- XamlFigureLengthSerializer.cs
- ZipIOCentralDirectoryBlock.cs
- SqlLiftWhereClauses.cs
- AlternateView.cs
- NestedContainer.cs
- RoleManagerEventArgs.cs
- LazyInitializer.cs
- WebPartRestoreVerb.cs
- UnitySerializationHolder.cs
- TimeSpanValidator.cs
- objectresult_tresulttype.cs
- DSASignatureFormatter.cs
- WindowsAltTab.cs
- StructuredTypeEmitter.cs
- QilReference.cs
- DataSourceView.cs
- ListCommandEventArgs.cs
- StrongNameUtility.cs
- TabRenderer.cs
- SerializationSectionGroup.cs
- RelationshipConverter.cs
- CodePropertyReferenceExpression.cs
- XmlArrayItemAttributes.cs
- TableRowCollection.cs
- RowToParametersTransformer.cs
- XPathSelectionIterator.cs
- WebPartDisplayModeCollection.cs
- DependencyPropertyChangedEventArgs.cs
- XmlSubtreeReader.cs
- WrappedIUnknown.cs
- FactorySettingsElement.cs
- XmlDataDocument.cs
- ManagedCodeMarkers.cs
- PathFigure.cs
- EdmValidator.cs
- PersonalizationDictionary.cs
- XPathException.cs
- AllMembershipCondition.cs
- SortExpressionBuilder.cs
- InstallerTypeAttribute.cs
- ReadingWritingEntityEventArgs.cs
- selecteditemcollection.cs
- SqlProfileProvider.cs
- Events.cs
- DefaultTraceListener.cs
- CollectionViewGroupRoot.cs
- XmlILIndex.cs
- PanelStyle.cs
- ConnectionStringsSection.cs
- iisPickupDirectory.cs
- TraceHwndHost.cs
- SessionState.cs
- UpdateException.cs
- OleDbConnectionFactory.cs
- OracleConnectionString.cs
- SqlBooleanMismatchVisitor.cs
- XmlKeywords.cs
- CryptoConfig.cs
- _BaseOverlappedAsyncResult.cs