Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / clr / src / BCL / System / InsufficientMemoryException.cs / 1 / InsufficientMemoryException.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: InsufficientMemoryException ** ** ** Purpose: The exception class for running out of memory ** but most likely in a non-fatal way that shouldn't ** be affected by escalation policy. Use this for cases ** like MemoryFailPoint or a TryAllocate method, where you ** expect OOM's with no shared state corruption and you ** want to recover from these errors. ** ** =============================================================================*/ namespace System { using System; using System.Runtime.Serialization; [Serializable()] public sealed class InsufficientMemoryException : OutOfMemoryException { public InsufficientMemoryException() : base(GetMessageFromNativeResources(ExceptionMessageKind.OutOfMemory)) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } public InsufficientMemoryException(String message) : base(message) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } public InsufficientMemoryException(String message, Exception innerException) : base(message, innerException) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } private InsufficientMemoryException(SerializationInfo info, StreamingContext context) : base(info, context) { } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: InsufficientMemoryException ** ** ** Purpose: The exception class for running out of memory ** but most likely in a non-fatal way that shouldn't ** be affected by escalation policy. Use this for cases ** like MemoryFailPoint or a TryAllocate method, where you ** expect OOM's with no shared state corruption and you ** want to recover from these errors. ** ** =============================================================================*/ namespace System { using System; using System.Runtime.Serialization; [Serializable()] public sealed class InsufficientMemoryException : OutOfMemoryException { public InsufficientMemoryException() : base(GetMessageFromNativeResources(ExceptionMessageKind.OutOfMemory)) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } public InsufficientMemoryException(String message) : base(message) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } public InsufficientMemoryException(String message, Exception innerException) : base(message, innerException) { SetErrorCode(__HResults.COR_E_INSUFFICIENTMEMORY); } private InsufficientMemoryException(SerializationInfo info, StreamingContext context) : base(info, context) { } } } // 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
- DocumentSchemaValidator.cs
- MimeTypePropertyAttribute.cs
- ContentFileHelper.cs
- PropagatorResult.cs
- CompressStream.cs
- DynamicResourceExtensionConverter.cs
- cookie.cs
- AnonymousIdentificationSection.cs
- AttributeTable.cs
- RowUpdatingEventArgs.cs
- MdiWindowListItemConverter.cs
- UIHelper.cs
- ValidationEventArgs.cs
- StringValidatorAttribute.cs
- CheckedPointers.cs
- DbParameterHelper.cs
- ListControlDataBindingHandler.cs
- FixUp.cs
- AspCompat.cs
- LineGeometry.cs
- KeyMatchBuilder.cs
- PolyQuadraticBezierSegment.cs
- IDictionary.cs
- WebServiceEndpoint.cs
- TreeViewBindingsEditorForm.cs
- TextRangeEdit.cs
- UniqueCodeIdentifierScope.cs
- DataGridViewCellFormattingEventArgs.cs
- SoapAttributeOverrides.cs
- CompositeDesignerAccessibleObject.cs
- DurableInstance.cs
- SafeNativeMethods.cs
- HitTestResult.cs
- CheckPair.cs
- ContainerUtilities.cs
- FileUtil.cs
- HwndMouseInputProvider.cs
- EncodingNLS.cs
- WpfGeneratedKnownProperties.cs
- TemplateContent.cs
- StatusBar.cs
- HierarchicalDataTemplate.cs
- ApplicationSecurityManager.cs
- DoubleKeyFrameCollection.cs
- SystemUdpStatistics.cs
- ValidationError.cs
- WinFormsUtils.cs
- Overlapped.cs
- DefaultAsyncDataDispatcher.cs
- WindowsButton.cs
- CookieParameter.cs
- UnsafeNativeMethods.cs
- BlurEffect.cs
- TableRow.cs
- ToolboxSnapDragDropEventArgs.cs
- RunInstallerAttribute.cs
- ExpandCollapsePattern.cs
- SocketInformation.cs
- InputLangChangeRequestEvent.cs
- IssuedSecurityTokenParameters.cs
- ClockGroup.cs
- BamlMapTable.cs
- GridViewCellAutomationPeer.cs
- ToolStripControlHost.cs
- EntityClientCacheKey.cs
- DataSourceProvider.cs
- XPathDescendantIterator.cs
- Lasso.cs
- CultureInfo.cs
- BamlResourceSerializer.cs
- XmlSerializerFactory.cs
- XXXOnTypeBuilderInstantiation.cs
- InlinedAggregationOperatorEnumerator.cs
- ListViewItemEventArgs.cs
- EventEntry.cs
- ImageCollectionEditor.cs
- ExtendedProtectionPolicyTypeConverter.cs
- NestPullup.cs
- IISMapPath.cs
- SortAction.cs
- SourceChangedEventArgs.cs
- WebPartManager.cs
- WindowsTokenRoleProvider.cs
- SchemaSetCompiler.cs
- DesignerActionHeaderItem.cs
- EmbeddedMailObjectsCollection.cs
- RegexParser.cs
- StringComparer.cs
- SourceItem.cs
- DoubleLinkListEnumerator.cs
- NominalTypeEliminator.cs
- Environment.cs
- QueryTaskGroupState.cs
- FullTextState.cs
- _PooledStream.cs
- ProgramPublisher.cs
- AutomationPropertyInfo.cs
- IndexExpression.cs
- DocumentPageHost.cs
- Encoding.cs