Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / Common / AuthoringOM / Compiler / Validation / WorkflowValidationFailedException.cs / 1305376 / WorkflowValidationFailedException.cs
namespace System.Workflow.ComponentModel.Compiler { using System; using System.Runtime.Serialization; using System.Collections.Generic; using System.Security.Permissions; [Serializable()] public sealed class WorkflowValidationFailedException : Exception { private ValidationErrorCollection errors = null; private WorkflowValidationFailedException(SerializationInfo info, StreamingContext context) : base(info, context) { if (info == null) throw new ArgumentNullException("info"); this.errors = (ValidationErrorCollection)info.GetValue("errors", typeof(ValidationErrorCollection)); if (this.errors == null) throw new SerializationException(SR.GetString(SR.Error_SerializationInsufficientState)); } public WorkflowValidationFailedException() : base(SR.GetString(SR.Error_WorkflowLoadValidationFailed)) { } public WorkflowValidationFailedException(string message) : base(message) { } public WorkflowValidationFailedException(string message, Exception innerException) : base(message, innerException) { } public WorkflowValidationFailedException(string message, ValidationErrorCollection errors) : base(message) { if (errors == null) throw new ArgumentNullException("errors"); this.errors = XomlCompilerHelper.MorphIntoFriendlyValidationErrors(errors); } public override void GetObjectData(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); base.GetObjectData(info, context); //ValidationErrorCollection is serializable info.AddValue("errors", this.errors, typeof(ValidationErrorCollection)); } public ValidationErrorCollection Errors { get { return this.errors; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. namespace System.Workflow.ComponentModel.Compiler { using System; using System.Runtime.Serialization; using System.Collections.Generic; using System.Security.Permissions; [Serializable()] public sealed class WorkflowValidationFailedException : Exception { private ValidationErrorCollection errors = null; private WorkflowValidationFailedException(SerializationInfo info, StreamingContext context) : base(info, context) { if (info == null) throw new ArgumentNullException("info"); this.errors = (ValidationErrorCollection)info.GetValue("errors", typeof(ValidationErrorCollection)); if (this.errors == null) throw new SerializationException(SR.GetString(SR.Error_SerializationInsufficientState)); } public WorkflowValidationFailedException() : base(SR.GetString(SR.Error_WorkflowLoadValidationFailed)) { } public WorkflowValidationFailedException(string message) : base(message) { } public WorkflowValidationFailedException(string message, Exception innerException) : base(message, innerException) { } public WorkflowValidationFailedException(string message, ValidationErrorCollection errors) : base(message) { if (errors == null) throw new ArgumentNullException("errors"); this.errors = XomlCompilerHelper.MorphIntoFriendlyValidationErrors(errors); } public override void GetObjectData(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); base.GetObjectData(info, context); //ValidationErrorCollection is serializable info.AddValue("errors", this.errors, typeof(ValidationErrorCollection)); } public ValidationErrorCollection Errors { get { return this.errors; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- BindingList.cs
- ExtentCqlBlock.cs
- SqlProviderUtilities.cs
- PageContentCollection.cs
- CheckBoxStandardAdapter.cs
- ColorTransform.cs
- ResourceDisplayNameAttribute.cs
- EditorPartChrome.cs
- Blend.cs
- DefaultPropertyAttribute.cs
- TabItemAutomationPeer.cs
- GCHandleCookieTable.cs
- InternalConfigRoot.cs
- SingleAnimationUsingKeyFrames.cs
- IpcPort.cs
- WasHostedComPlusFactory.cs
- ConfigXmlAttribute.cs
- MessageQueueException.cs
- ProcessHostMapPath.cs
- BinaryConverter.cs
- ScriptResourceAttribute.cs
- ThemeInfoAttribute.cs
- PassportAuthentication.cs
- Block.cs
- SystemNetworkInterface.cs
- ReadOnlyCollection.cs
- _BufferOffsetSize.cs
- CodeEventReferenceExpression.cs
- InvalidEnumArgumentException.cs
- _WebProxyDataBuilder.cs
- ConstructorNeedsTagAttribute.cs
- WorkflowItemPresenter.cs
- IgnoreDeviceFilterElement.cs
- ISFTagAndGuidCache.cs
- DebugTraceHelper.cs
- HtmlShimManager.cs
- ProfileService.cs
- ListViewCancelEventArgs.cs
- TreeViewItemAutomationPeer.cs
- Vector3DAnimationBase.cs
- CircleHotSpot.cs
- BindableAttribute.cs
- ProviderCommandInfoUtils.cs
- ComplexPropertyEntry.cs
- AnimationLayer.cs
- VsPropertyGrid.cs
- SoapExtensionTypeElementCollection.cs
- ReturnEventArgs.cs
- InternalResources.cs
- EventWaitHandle.cs
- NamespaceCollection.cs
- GeneralTransform3DTo2D.cs
- RichTextBox.cs
- AsyncOperation.cs
- StringAnimationUsingKeyFrames.cs
- WsdlInspector.cs
- HitTestParameters3D.cs
- FormatConvertedBitmap.cs
- CodeDirectionExpression.cs
- Handle.cs
- MimeTypeMapper.cs
- InstanceCreationEditor.cs
- Enlistment.cs
- Point.cs
- UInt16Converter.cs
- CustomWebEventKey.cs
- SnapLine.cs
- CommittableTransaction.cs
- XmlSchemaGroup.cs
- BufferedWebEventProvider.cs
- SpellerStatusTable.cs
- Annotation.cs
- TextDecorationUnitValidation.cs
- figurelength.cs
- Missing.cs
- String.cs
- WebPartVerb.cs
- SelectedDatesCollection.cs
- AssemblySettingAttributes.cs
- KerberosSecurityTokenProvider.cs
- AstNode.cs
- MimeReturn.cs
- ListItemConverter.cs
- RequiredAttributeAttribute.cs
- SingleSelectRootGridEntry.cs
- SiteMapNodeItem.cs
- InkPresenterAutomationPeer.cs
- Pkcs7Signer.cs
- Trustee.cs
- SqlNamer.cs
- ExeContext.cs
- EntityDataSourceContextDisposingEventArgs.cs
- WebMethodAttribute.cs
- AbsoluteQuery.cs
- ParserExtension.cs
- CellIdBoolean.cs
- CustomWebEventKey.cs
- DataSourceControl.cs
- Model3DGroup.cs
- JavascriptCallbackBehaviorAttribute.cs