Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / clr / src / BCL / System / NotFiniteNumberException.cs / 1 / NotFiniteNumberException.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== namespace System { using System; using System.Runtime.Serialization; using System.Security.Permissions; [System.Runtime.InteropServices.ComVisible(true)] [Serializable()] public class NotFiniteNumberException : ArithmeticException { private double _offendingNumber; public NotFiniteNumberException() : base(Environment.GetResourceString("Arg_NotFiniteNumberException")) { _offendingNumber = 0; SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } public NotFiniteNumberException(double offendingNumber) : base() { _offendingNumber = offendingNumber; SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } public NotFiniteNumberException(String message) : base(message) { _offendingNumber = 0; SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } public NotFiniteNumberException(String message, double offendingNumber) : base(message) { _offendingNumber = offendingNumber; SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } public NotFiniteNumberException(String message, Exception innerException) : base(message, innerException) { SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } public NotFiniteNumberException(String message, double offendingNumber, Exception innerException) : base(message, innerException) { _offendingNumber = offendingNumber; SetErrorCode(__HResults.COR_E_NOTFINITENUMBER); } protected NotFiniteNumberException(SerializationInfo info, StreamingContext context) : base(info, context) { _offendingNumber = info.GetInt32("OffendingNumber"); } public double OffendingNumber { get { return _offendingNumber; } } [SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags=SecurityPermissionFlag.SerializationFormatter)] public override void GetObjectData(SerializationInfo info, StreamingContext context) { if (info==null) { throw new ArgumentNullException("info"); } base.GetObjectData(info, context); info.AddValue("OffendingNumber", _offendingNumber, typeof(Int32)); } } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RuleSettings.cs
- SqlWorkflowInstanceStoreLock.cs
- XamlSerializerUtil.cs
- UIPermission.cs
- RuntimeConfig.cs
- WebConfigurationManager.cs
- DiscardableAttribute.cs
- ConsumerConnectionPoint.cs
- ProgressBar.cs
- SymbolMethod.cs
- Soap12ProtocolImporter.cs
- XmlAnyElementAttributes.cs
- CoTaskMemSafeHandle.cs
- SqlDataSourceView.cs
- ShapeTypeface.cs
- StoreAnnotationsMap.cs
- ProfileManager.cs
- ProfileBuildProvider.cs
- HttpResponseHeader.cs
- FormsAuthenticationUserCollection.cs
- RtfNavigator.cs
- ItemsPresenter.cs
- SmiEventSink_DeferedProcessing.cs
- WaitHandleCannotBeOpenedException.cs
- TcpConnectionPoolSettingsElement.cs
- DataListGeneralPage.cs
- EventTask.cs
- Vertex.cs
- RepeatButton.cs
- TextElementAutomationPeer.cs
- PaginationProgressEventArgs.cs
- OrderByBuilder.cs
- ManipulationStartingEventArgs.cs
- util.cs
- ApplicationDirectoryMembershipCondition.cs
- BadImageFormatException.cs
- DocumentStatusResources.cs
- ConsumerConnectionPoint.cs
- _AutoWebProxyScriptWrapper.cs
- XPathNavigatorReader.cs
- RequestQueue.cs
- JsonReaderWriterFactory.cs
- TypedRowHandler.cs
- StylusSystemGestureEventArgs.cs
- OverrideMode.cs
- CacheOutputQuery.cs
- LayoutTable.cs
- SHA384.cs
- CapabilitiesUse.cs
- PropertyDescriptorCollection.cs
- DuplicateWaitObjectException.cs
- TokenBasedSetEnumerator.cs
- SqlBooleanMismatchVisitor.cs
- DesignerLoader.cs
- XmlMapping.cs
- PropertyFilterAttribute.cs
- Sentence.cs
- XmlSubtreeReader.cs
- HtmlButton.cs
- PropertyPath.cs
- TemplateXamlParser.cs
- MdiWindowListStrip.cs
- filewebresponse.cs
- NativeObjectSecurity.cs
- PackageRelationshipSelector.cs
- OpenCollectionAsyncResult.cs
- CellNormalizer.cs
- ChineseLunisolarCalendar.cs
- AsyncPostBackErrorEventArgs.cs
- LogicalExpr.cs
- XamlReader.cs
- OrderByLifter.cs
- ProcessHostFactoryHelper.cs
- Material.cs
- SqlConnectionPoolGroupProviderInfo.cs
- QilSortKey.cs
- ApplyImportsAction.cs
- UniqueConstraint.cs
- SystemIPGlobalProperties.cs
- AppSettingsExpressionEditor.cs
- ConfigXmlCDataSection.cs
- RandomNumberGenerator.cs
- HtmlTitle.cs
- CapacityStreamGeometryContext.cs
- ToolboxItemFilterAttribute.cs
- StringKeyFrameCollection.cs
- PickDesigner.xaml.cs
- CodeVariableDeclarationStatement.cs
- ShutDownListener.cs
- WindowsGraphicsWrapper.cs
- UdpTransportBindingElement.cs
- SelectedCellsChangedEventArgs.cs
- TextBoxAutoCompleteSourceConverter.cs
- ListParaClient.cs
- DataTableNewRowEvent.cs
- RichTextBox.cs
- TimeSpanStorage.cs
- Activator.cs
- Point.cs
- Formatter.cs