Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / InvalidEnumArgumentException.cs / 1 / InvalidEnumArgumentException.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using Microsoft.Win32; using System; using System.Diagnostics; using System.Globalization; using System.Runtime.Serialization; using System.Security.Permissions; ////// [HostProtection(SharedState = true)] [Serializable] public class InvalidEnumArgumentException : ArgumentException { ///The exception that is thrown when using invalid arguments that are enumerators. ////// public InvalidEnumArgumentException() : this(null) { } ///Initializes a new instance of the ///class without a message. /// public InvalidEnumArgumentException(string message) : base(message) { } ///Initializes a new instance of the ///class with /// the specified message. /// Initializes a new instance of the Exception class with a specified error message and a /// reference to the inner exception that is the cause of this exception. /// FxCop CA1032: Multiple constructors are required to correctly implement a custom exception. /// public InvalidEnumArgumentException( string message, Exception innerException ) : base(message, innerException) { } ////// public InvalidEnumArgumentException(string argumentName, int invalidValue, Type enumClass) : base(SR.GetString(SR.InvalidEnumArgument, argumentName, invalidValue.ToString(CultureInfo.CurrentCulture), enumClass.Name), argumentName) { } ///Initializes a new instance of the ///class with a /// message generated from the argument, invalid value, and enumeration /// class. /// Need this constructor since Exception implements ISerializable. We don't have any fields, /// so just forward this to base. /// protected InvalidEnumArgumentException(SerializationInfo info, StreamingContext context) : base(info, context) { } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- LocatorBase.cs
- PackWebResponse.cs
- MethodRental.cs
- FillBehavior.cs
- BehaviorEditorPart.cs
- AuthenticationConfig.cs
- SuppressMergeCheckAttribute.cs
- MulticastIPAddressInformationCollection.cs
- ChooseAction.cs
- HtmlImage.cs
- GradientSpreadMethodValidation.cs
- StorageEntityContainerMapping.cs
- ViewManager.cs
- SmiMetaDataProperty.cs
- PageBuildProvider.cs
- ListControlActionList.cs
- Registry.cs
- Content.cs
- NativeBuffer.cs
- DesignerForm.cs
- DataTemplateSelector.cs
- TimersDescriptionAttribute.cs
- CommandDevice.cs
- ObjectViewListener.cs
- CodeTypeMember.cs
- iisPickupDirectory.cs
- XmlWhitespace.cs
- ProgressBar.cs
- SectionRecord.cs
- AdjustableArrowCap.cs
- DispatchWrapper.cs
- TemplateNameScope.cs
- ThrowOnMultipleAssignment.cs
- ClientTargetSection.cs
- PerfCounters.cs
- ETagAttribute.cs
- ProfileEventArgs.cs
- DesignerVerbCollection.cs
- StylusButtonEventArgs.cs
- TextMarkerSource.cs
- ProfileProvider.cs
- DocobjHost.cs
- WebPartHelpVerb.cs
- TouchDevice.cs
- OracleColumn.cs
- UniqueConstraint.cs
- EntryPointNotFoundException.cs
- WebEventCodes.cs
- CustomError.cs
- DockAndAnchorLayout.cs
- ScriptIgnoreAttribute.cs
- StringCollection.cs
- StateInitializationDesigner.cs
- PropertySourceInfo.cs
- CompressEmulationStream.cs
- ImageAnimator.cs
- ExpandSegmentCollection.cs
- RijndaelManagedTransform.cs
- ContainerFilterService.cs
- RequestQueryProcessor.cs
- EventRouteFactory.cs
- UIHelper.cs
- WindowsFormsHelpers.cs
- PanelStyle.cs
- DefaultPrintController.cs
- ConfigXmlText.cs
- TrackingLocation.cs
- JournalEntry.cs
- PrefixQName.cs
- Asn1IntegerConverter.cs
- MenuItemStyleCollection.cs
- BounceEase.cs
- ToggleProviderWrapper.cs
- FixedDocumentSequencePaginator.cs
- MatchingStyle.cs
- OutputBuffer.cs
- DbConnectionClosed.cs
- ImageSource.cs
- XmlQualifiedNameTest.cs
- BoundPropertyEntry.cs
- DirectoryNotFoundException.cs
- ObservableCollectionDefaultValueFactory.cs
- _emptywebproxy.cs
- DecimalFormatter.cs
- Comparer.cs
- RequiredAttributeAttribute.cs
- DataSourceSelectArguments.cs
- SQLString.cs
- CachedFontFamily.cs
- SafeArrayTypeMismatchException.cs
- IsolationInterop.cs
- HostProtectionPermission.cs
- DbCommandTree.cs
- MetadataSerializer.cs
- CodePageUtils.cs
- GeometryCollection.cs
- ManipulationInertiaStartingEventArgs.cs
- TextModifier.cs
- XmlDataDocument.cs
- WebPartVerbCollection.cs