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
- TrackingCondition.cs
- PathData.cs
- Int16Converter.cs
- ISessionStateStore.cs
- ComEventsMethod.cs
- TextProperties.cs
- SafeNativeMemoryHandle.cs
- ObjectContextServiceProvider.cs
- FeatureSupport.cs
- TemplateKeyConverter.cs
- GlobalizationAssembly.cs
- CriticalFinalizerObject.cs
- XmlHierarchicalDataSourceView.cs
- SafeFileMapViewHandle.cs
- MarshalByValueComponent.cs
- SharedPerformanceCounter.cs
- MessageDecoder.cs
- MenuEventArgs.cs
- CodeEventReferenceExpression.cs
- _HeaderInfo.cs
- Line.cs
- CommandHelpers.cs
- DataObjectAttribute.cs
- IDReferencePropertyAttribute.cs
- RectangleGeometry.cs
- MsmqIntegrationMessageProperty.cs
- DialogDivider.cs
- EndpointInfo.cs
- ProcessModuleCollection.cs
- PopupRootAutomationPeer.cs
- CharConverter.cs
- CodeTypeDelegate.cs
- SafeFileHandle.cs
- PropertyToken.cs
- DataGridViewImageColumn.cs
- TimeStampChecker.cs
- SmtpNegotiateAuthenticationModule.cs
- TableRowCollection.cs
- FontNamesConverter.cs
- PropVariant.cs
- HashHelpers.cs
- WebPartsSection.cs
- InternalsVisibleToAttribute.cs
- DataObjectEventArgs.cs
- Identity.cs
- xamlnodes.cs
- UnsafeNativeMethods.cs
- BamlLocalizerErrorNotifyEventArgs.cs
- AsymmetricKeyExchangeFormatter.cs
- QilInvokeEarlyBound.cs
- Light.cs
- FileDialog.cs
- SequenceQuery.cs
- ReadOnlyNameValueCollection.cs
- WebPartEditorApplyVerb.cs
- RangeValidator.cs
- DeflateStreamAsyncResult.cs
- Content.cs
- ISAPIRuntime.cs
- FlowSwitchDesigner.xaml.cs
- RegexCode.cs
- RIPEMD160Managed.cs
- AsnEncodedData.cs
- InteropEnvironment.cs
- Frame.cs
- FamilyTypefaceCollection.cs
- XhtmlCssHandler.cs
- OpacityConverter.cs
- ResourceDefaultValueAttribute.cs
- UrlMapping.cs
- SharedDp.cs
- COM2ExtendedUITypeEditor.cs
- ViewCellRelation.cs
- EventWaitHandle.cs
- ResourceExpression.cs
- DataControlFieldCollection.cs
- CompareValidator.cs
- ProviderManager.cs
- MissingSatelliteAssemblyException.cs
- XpsStructure.cs
- BindMarkupExtensionSerializer.cs
- DesignOnlyAttribute.cs
- FileLevelControlBuilderAttribute.cs
- OrderedDictionary.cs
- MissingManifestResourceException.cs
- DateTimeUtil.cs
- XslAst.cs
- EventLog.cs
- ReservationNotFoundException.cs
- AsyncOperationManager.cs
- Divide.cs
- SingleAnimationUsingKeyFrames.cs
- LogLogRecordHeader.cs
- ApplicationCommands.cs
- TransactedReceiveScope.cs
- LinqDataSourceInsertEventArgs.cs
- QuadraticBezierSegment.cs
- X500Name.cs
- SharedDp.cs
- BuildProvider.cs