Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / System / InsufficientMemoryException.cs / 1305376 / 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
- ControlValuePropertyAttribute.cs
- EventMap.cs
- ExitEventArgs.cs
- CacheForPrimitiveTypes.cs
- CollectionViewGroup.cs
- StorageEndPropertyMapping.cs
- GenerateTemporaryTargetAssembly.cs
- UserControlParser.cs
- Perspective.cs
- KeyPressEvent.cs
- BuilderInfo.cs
- ImageDrawing.cs
- TouchEventArgs.cs
- ChangeInterceptorAttribute.cs
- isolationinterop.cs
- XmlSchemaObjectCollection.cs
- ConnectionStringSettings.cs
- DbConnectionHelper.cs
- TemplateInstanceAttribute.cs
- WebPartZone.cs
- WebUtil.cs
- ConfigurationLocation.cs
- StylusSystemGestureEventArgs.cs
- LicenseContext.cs
- COM2Enum.cs
- LinkDescriptor.cs
- DataServiceProcessingPipelineEventArgs.cs
- ArglessEventHandlerProxy.cs
- UniqueContractNameValidationBehavior.cs
- InstalledFontCollection.cs
- FastEncoderWindow.cs
- VScrollProperties.cs
- PaginationProgressEventArgs.cs
- EncoderFallback.cs
- StrongNameIdentityPermission.cs
- DesignConnectionCollection.cs
- RemotingSurrogateSelector.cs
- AutomationIdentifier.cs
- DataGridHeaderBorder.cs
- Grammar.cs
- EnumConverter.cs
- EventLog.cs
- DataGridViewSortCompareEventArgs.cs
- CombinedGeometry.cs
- EdmItemCollection.cs
- KeyboardEventArgs.cs
- EdmPropertyAttribute.cs
- DependencyPropertyKind.cs
- CodeMethodInvokeExpression.cs
- CustomLineCap.cs
- MultiTouchSystemGestureLogic.cs
- TemplatePartAttribute.cs
- PropertyInformation.cs
- AncestorChangedEventArgs.cs
- WinInet.cs
- TypeHelper.cs
- Number.cs
- XmlSchemaComplexContentRestriction.cs
- DataControlField.cs
- UserControlDocumentDesigner.cs
- SqlConnectionStringBuilder.cs
- DXD.cs
- ButtonStandardAdapter.cs
- ConfigXmlSignificantWhitespace.cs
- WebDisplayNameAttribute.cs
- DragDeltaEventArgs.cs
- SortedDictionary.cs
- HtmlValidationSummaryAdapter.cs
- CanonicalXml.cs
- AssemblyResourceLoader.cs
- SemanticTag.cs
- BamlWriter.cs
- EntityDataSourceDataSelection.cs
- WebRequest.cs
- FileEnumerator.cs
- XmlComplianceUtil.cs
- Helpers.cs
- XPathDocumentIterator.cs
- QueryTaskGroupState.cs
- DbInsertCommandTree.cs
- MetafileHeader.cs
- FaultPropagationRecord.cs
- ResourcesChangeInfo.cs
- PropertyInformation.cs
- CultureInfoConverter.cs
- DoubleAnimation.cs
- WorkflowExecutor.cs
- ButtonBase.cs
- SiteMapProvider.cs
- TextServicesManager.cs
- RSAOAEPKeyExchangeDeformatter.cs
- basecomparevalidator.cs
- ConnectionProviderAttribute.cs
- SQLBytes.cs
- BufferBuilder.cs
- TypeProvider.cs
- BaseTemplateParser.cs
- ConnectionOrientedTransportElement.cs
- MasterPageParser.cs
- ApplyImportsAction.cs