Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / clr / src / BCL / System / Runtime / CompilerServices / RuntimeWrappedException.cs / 1 / RuntimeWrappedException.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: RuntimeWrappedException ** ** ** Purpose: The exception class uses to wrap all non-CLS compliant exceptions. ** ** =============================================================================*/ namespace System.Runtime.CompilerServices { using System; using System.Runtime.Serialization; using System.Runtime.Remoting; using System.Security.Permissions; [Serializable()] public sealed class RuntimeWrappedException : Exception { private RuntimeWrappedException(Object thrownObject) : base(Environment.GetResourceString("RuntimeWrappedException")) { SetErrorCode(System.__HResults.COR_E_RUNTIMEWRAPPED); m_wrappedException = thrownObject; } public Object WrappedException { get { return m_wrappedException; } } private Object m_wrappedException; [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("WrappedException", m_wrappedException, typeof(Object)); } internal RuntimeWrappedException(SerializationInfo info, StreamingContext context) : base(info, context) { m_wrappedException = info.GetValue("WrappedException", typeof(Object)); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: RuntimeWrappedException ** ** ** Purpose: The exception class uses to wrap all non-CLS compliant exceptions. ** ** =============================================================================*/ namespace System.Runtime.CompilerServices { using System; using System.Runtime.Serialization; using System.Runtime.Remoting; using System.Security.Permissions; [Serializable()] public sealed class RuntimeWrappedException : Exception { private RuntimeWrappedException(Object thrownObject) : base(Environment.GetResourceString("RuntimeWrappedException")) { SetErrorCode(System.__HResults.COR_E_RUNTIMEWRAPPED); m_wrappedException = thrownObject; } public Object WrappedException { get { return m_wrappedException; } } private Object m_wrappedException; [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("WrappedException", m_wrappedException, typeof(Object)); } internal RuntimeWrappedException(SerializationInfo info, StreamingContext context) : base(info, context) { m_wrappedException = info.GetValue("WrappedException", typeof(Object)); } } } // 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
- MonitoringDescriptionAttribute.cs
- SqlBuffer.cs
- _UncName.cs
- PropertyEntry.cs
- SelectionRangeConverter.cs
- HtmlHead.cs
- NonParentingControl.cs
- Errors.cs
- SchemaTypeEmitter.cs
- MatchingStyle.cs
- FloatAverageAggregationOperator.cs
- SoapFault.cs
- CatalogPartCollection.cs
- Rect.cs
- SecureUICommand.cs
- CompilerResults.cs
- FileLoadException.cs
- NetworkInformationPermission.cs
- UniqueSet.cs
- ClientFormsAuthenticationCredentials.cs
- InputReportEventArgs.cs
- WebServicesSection.cs
- SiteMapNode.cs
- DataKeyArray.cs
- Visual3D.cs
- UserNamePasswordValidationMode.cs
- PasswordPropertyTextAttribute.cs
- DataGridViewCellStyle.cs
- ViewBox.cs
- FindSimilarActivitiesVerb.cs
- Touch.cs
- WhitespaceRuleReader.cs
- AnnotationAdorner.cs
- VisualBasicExpressionConverter.cs
- DriveNotFoundException.cs
- EntitySetDataBindingList.cs
- SelectedDatesCollection.cs
- SuppressIldasmAttribute.cs
- Publisher.cs
- ShaperBuffers.cs
- ItemType.cs
- BitmapEffectInput.cs
- ProgressBarAutomationPeer.cs
- Image.cs
- SqlInternalConnection.cs
- XmlAttributeProperties.cs
- SystemIPInterfaceStatistics.cs
- ReplacementText.cs
- TreeNodeClickEventArgs.cs
- SafeFileMapViewHandle.cs
- SerializationInfo.cs
- PerfCounters.cs
- BamlLocalizer.cs
- ParserContext.cs
- MouseGesture.cs
- TextUtf8RawTextWriter.cs
- TreeChangeInfo.cs
- FieldAccessException.cs
- Vars.cs
- CryptoApi.cs
- StickyNoteHelper.cs
- DataGridSortingEventArgs.cs
- GroupBoxRenderer.cs
- HtmlShim.cs
- ImageMetadata.cs
- PkcsMisc.cs
- GraphicsContext.cs
- SoapAttributeAttribute.cs
- Vector3DAnimationUsingKeyFrames.cs
- StrongTypingException.cs
- VariableAction.cs
- TranslateTransform3D.cs
- Matrix.cs
- UTF32Encoding.cs
- Set.cs
- serverconfig.cs
- RotationValidation.cs
- GridViewUpdateEventArgs.cs
- ValidationResult.cs
- ZipIOZip64EndOfCentralDirectoryLocatorBlock.cs
- XmlNotation.cs
- TemplateComponentConnector.cs
- DetailsViewPageEventArgs.cs
- OletxEnlistment.cs
- MetadataItemEmitter.cs
- MessageDirection.cs
- ReaderWriterLock.cs
- serverconfig.cs
- Processor.cs
- EntitySqlQueryState.cs
- XPathItem.cs
- XamlSerializerUtil.cs
- ServicePointManager.cs
- TextChangedEventArgs.cs
- AlignmentXValidation.cs
- MemoryStream.cs
- ScriptModule.cs
- BrowserCapabilitiesCodeGenerator.cs
- WebSysDescriptionAttribute.cs
- PageStatePersister.cs