Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / clr / src / BCL / System / ArgumentNullException.cs / 1 / ArgumentNullException.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: ArgumentNullException ** ** ** Purpose: Exception class for null arguments to a method. ** ** =============================================================================*/ namespace System { using System; using System.Runtime.Serialization; using System.Runtime.Remoting; using System.Security.Permissions; // The ArgumentException is thrown when an argument // is null when it shouldn't be. // [System.Runtime.InteropServices.ComVisible(true)] [Serializable] public class ArgumentNullException : ArgumentException { // Creates a new ArgumentNullException with its message // string set to a default message explaining an argument was null. public ArgumentNullException() : base(Environment.GetResourceString("ArgumentNull_Generic")) { // Use E_POINTER - COM used that for null pointers. Description is "invalid pointer" SetErrorCode(__HResults.E_POINTER); } public ArgumentNullException(String paramName) : base(Environment.GetResourceString("ArgumentNull_Generic"), paramName) { SetErrorCode(__HResults.E_POINTER); } public ArgumentNullException(String message, Exception innerException) : base(message, innerException) { SetErrorCode(__HResults.E_POINTER); } public ArgumentNullException(String paramName, String message) : base(message, paramName) { SetErrorCode(__HResults.E_POINTER); } [SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags=SecurityPermissionFlag.SerializationFormatter)] protected ArgumentNullException(SerializationInfo info, StreamingContext context) : base(info, context) { } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebPartDescription.cs
- MetadataArtifactLoaderResource.cs
- TableStyle.cs
- ExpressionVisitor.cs
- WindowsEditBox.cs
- XsltLibrary.cs
- DbParameterHelper.cs
- TreeViewDesigner.cs
- HostingEnvironmentException.cs
- Preprocessor.cs
- QueryAccessibilityHelpEvent.cs
- Module.cs
- FigureParaClient.cs
- ObjectSecurityT.cs
- DynamicPropertyReader.cs
- AnnotationService.cs
- EntitySetBase.cs
- ContextMenuStripActionList.cs
- SpellerHighlightLayer.cs
- ProfilePropertySettingsCollection.cs
- BulletedListEventArgs.cs
- DiagnosticsConfigurationHandler.cs
- SafeNativeMemoryHandle.cs
- MtomMessageEncodingBindingElement.cs
- CapabilitiesAssignment.cs
- Completion.cs
- TextTreeTextBlock.cs
- EnumMember.cs
- SmiMetaData.cs
- RepeaterCommandEventArgs.cs
- XmlAttributeProperties.cs
- StaticSiteMapProvider.cs
- ApplicationException.cs
- sqlser.cs
- nulltextnavigator.cs
- DesignerWidgets.cs
- ObjectListCommandEventArgs.cs
- baseshape.cs
- GraphicsPath.cs
- PackageRelationship.cs
- HtmlControlDesigner.cs
- Binding.cs
- GcSettings.cs
- GenericsInstances.cs
- CatalogZone.cs
- PointLight.cs
- Message.cs
- XmlComment.cs
- UInt32Converter.cs
- CompositionAdorner.cs
- RawStylusInputReport.cs
- TextPointerBase.cs
- NotImplementedException.cs
- CryptoApi.cs
- HtmlInputCheckBox.cs
- EntityCollection.cs
- WindowsGrip.cs
- QueryExtender.cs
- StringUtil.cs
- StrokeNodeOperations.cs
- DataGridViewRowStateChangedEventArgs.cs
- InputScopeConverter.cs
- LexicalChunk.cs
- VBCodeProvider.cs
- BitmapInitialize.cs
- XPathPatternBuilder.cs
- PositiveTimeSpanValidatorAttribute.cs
- QualifiedCellIdBoolean.cs
- DataGridItemCollection.cs
- ComponentChangedEvent.cs
- SchemaImporterExtensionElementCollection.cs
- XamlReader.cs
- InputScopeNameConverter.cs
- Rect3D.cs
- StatusBarAutomationPeer.cs
- HwndTarget.cs
- _LazyAsyncResult.cs
- COM2ExtendedTypeConverter.cs
- ChangeBlockUndoRecord.cs
- PropertyConverter.cs
- MessageAction.cs
- CodeSnippetTypeMember.cs
- CalendarDataBindingHandler.cs
- SqlTriggerContext.cs
- BasicCellRelation.cs
- DSACryptoServiceProvider.cs
- ConfigurationSettings.cs
- DataBindingHandlerAttribute.cs
- System.Data.OracleClient_BID.cs
- PagesSection.cs
- X509CertificateRecipientClientCredential.cs
- EventLogPermissionAttribute.cs
- CultureInfoConverter.cs
- ListViewGroupItemCollection.cs
- VectorValueSerializer.cs
- DataObjectAttribute.cs
- PagerSettings.cs
- Authorization.cs
- RoutedCommand.cs
- DatatypeImplementation.cs