Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / NetFx35 / System.WorkflowServices / System / ServiceModel / Dispatcher / ServiceErrorHandler.cs / 1305376 / ServiceErrorHandler.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.ServiceModel.Dispatcher { using System; using System.ServiceModel.Channels; using System.Collections; class ServiceErrorHandler : DurableErrorHandler { const string dataKey = "System.ServiceModel.Dispatcher.ServiceErrorHandler.MarkExeption"; public ServiceErrorHandler(bool debug) : base(debug) { } public static void MarkException(Exception toMark) { // From MSDN: The OutOfMemoryException, StackOverflowException and ThreadAbortException // classes always return a null reference for the value of the Data property. // These are fatal exceptions and therefore we don't care that we can't mark them. IDictionary data = toMark.Data; if (data != null && !data.IsReadOnly && !data.IsFixedSize) { data.Add(dataKey, true); } } protected override bool IsUserCodeException(Exception error) { IDictionary data = error.Data; if (data != null && data.Contains(dataKey)) { return true; } return false; } } } // 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
- CodeNamespaceImportCollection.cs
- BamlTreeUpdater.cs
- PromptBuilder.cs
- prefixendpointaddressmessagefiltertable.cs
- ApplicationSecurityManager.cs
- CompositeDataBoundControl.cs
- PermissionSet.cs
- CellTreeNodeVisitors.cs
- GridItemCollection.cs
- WeakReferenceList.cs
- DynamicValueConverter.cs
- ListViewItemEventArgs.cs
- PropertyPath.cs
- FormViewInsertedEventArgs.cs
- CopyNamespacesAction.cs
- Animatable.cs
- AlignmentXValidation.cs
- SpellerHighlightLayer.cs
- TreeViewAutomationPeer.cs
- SchemaCollectionPreprocessor.cs
- XmlNodeChangedEventManager.cs
- XmlHierarchyData.cs
- WhitespaceRuleReader.cs
- ReferenceSchema.cs
- UrlAuthFailedErrorFormatter.cs
- Model3DCollection.cs
- wgx_sdk_version.cs
- StylusPointPropertyId.cs
- OleDbConnection.cs
- ColorBlend.cs
- DataControlFieldCell.cs
- Transform.cs
- PropertyChangeTracker.cs
- TableLayoutRowStyleCollection.cs
- MainMenu.cs
- TransportConfigurationTypeElementCollection.cs
- DesignerActionPanel.cs
- EntityClassGenerator.cs
- CursorConverter.cs
- ObjectMemberMapping.cs
- SubstitutionList.cs
- Variant.cs
- WindowsSysHeader.cs
- CodeAttributeDeclaration.cs
- EntityClassGenerator.cs
- ReflectionServiceProvider.cs
- SystemIPv4InterfaceProperties.cs
- DataGridViewRowHeaderCell.cs
- SchemaMerger.cs
- assertwrapper.cs
- ExpressionBindingCollection.cs
- FormsAuthenticationUser.cs
- Point3DValueSerializer.cs
- AutoGeneratedField.cs
- NativeMethods.cs
- DataGridViewRowDividerDoubleClickEventArgs.cs
- QuaternionAnimationBase.cs
- DataGridViewElement.cs
- SqlParameter.cs
- XmlSchemaProviderAttribute.cs
- FixedStringLookup.cs
- SqlGatherProducedAliases.cs
- StylusPointPropertyUnit.cs
- Nullable.cs
- ParentQuery.cs
- Transform.cs
- HtmlTitle.cs
- CodeAttributeDeclarationCollection.cs
- Config.cs
- HtmlFormParameterReader.cs
- NameValueSectionHandler.cs
- BaseParagraph.cs
- AndMessageFilterTable.cs
- XmlILTrace.cs
- WebPartDisplayModeCancelEventArgs.cs
- Label.cs
- XmlAnyElementAttributes.cs
- LazyTextWriterCreator.cs
- InternalControlCollection.cs
- HttpHeaderCollection.cs
- _UriTypeConverter.cs
- WindowsFormsSectionHandler.cs
- WizardForm.cs
- XPathBinder.cs
- SectionVisual.cs
- XmlElementAttribute.cs
- Expressions.cs
- WindowsTreeView.cs
- SubqueryTrackingVisitor.cs
- GeneralTransform.cs
- StickyNote.cs
- HtmlImageAdapter.cs
- WebPartConnection.cs
- XPathQueryGenerator.cs
- GrammarBuilderWildcard.cs
- Monitor.cs
- ColorConverter.cs
- SourceFileBuildProvider.cs
- XPathAncestorQuery.cs
- EntityCollection.cs