Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / Common / AuthoringOM / Compiler / Validation / PropertyValidationContext.cs / 1305376 / PropertyValidationContext.cs
namespace System.Workflow.ComponentModel.Compiler { using System; using System.Reflection; #region PropertyValidationContext public sealed class PropertyValidationContext { private string propertyName = string.Empty; private object propertyOwner = null; private object propertyInfo = null; public PropertyValidationContext(object propertyOwner, PropertyInfo propertyInfo, string propertyName) { if (propertyName == null) throw new ArgumentNullException("propertyName"); if (propertyOwner == null) throw new ArgumentNullException("propertyOwner"); this.propertyOwner = propertyOwner; this.propertyName = propertyName; this.propertyInfo = propertyInfo; } public PropertyValidationContext(object propertyOwner, DependencyProperty dependencyProperty) { if (propertyOwner == null) throw new ArgumentNullException("propertyOwner"); this.propertyOwner = propertyOwner; this.propertyInfo = dependencyProperty; } public string PropertyName { get { if (this.propertyInfo is DependencyProperty) return ((DependencyProperty)this.propertyInfo).Name; else return this.propertyName; } } public object PropertyOwner { get { return this.propertyOwner; } } public object Property { get { return this.propertyInfo; } } } #endregion } // 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.Reflection; #region PropertyValidationContext public sealed class PropertyValidationContext { private string propertyName = string.Empty; private object propertyOwner = null; private object propertyInfo = null; public PropertyValidationContext(object propertyOwner, PropertyInfo propertyInfo, string propertyName) { if (propertyName == null) throw new ArgumentNullException("propertyName"); if (propertyOwner == null) throw new ArgumentNullException("propertyOwner"); this.propertyOwner = propertyOwner; this.propertyName = propertyName; this.propertyInfo = propertyInfo; } public PropertyValidationContext(object propertyOwner, DependencyProperty dependencyProperty) { if (propertyOwner == null) throw new ArgumentNullException("propertyOwner"); this.propertyOwner = propertyOwner; this.propertyInfo = dependencyProperty; } public string PropertyName { get { if (this.propertyInfo is DependencyProperty) return ((DependencyProperty)this.propertyInfo).Name; else return this.propertyName; } } public object PropertyOwner { get { return this.propertyOwner; } } public object Property { get { return this.propertyInfo; } } } #endregion } // 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
- Accessible.cs
- EntityViewContainer.cs
- ComponentManagerBroker.cs
- WebControl.cs
- RuntimeArgumentHandle.cs
- BoolExpressionVisitors.cs
- Converter.cs
- StreamGeometry.cs
- ShaperBuffers.cs
- ListViewCommandEventArgs.cs
- LazyTextWriterCreator.cs
- NativeActivityAbortContext.cs
- SectionXmlInfo.cs
- IndexedEnumerable.cs
- IndexerNameAttribute.cs
- MenuItemBinding.cs
- _NetworkingPerfCounters.cs
- EmptyControlCollection.cs
- DecimalStorage.cs
- PropertyItemInternal.cs
- CacheDependency.cs
- PageWrapper.cs
- Timer.cs
- DesignDataSource.cs
- QueryGenerator.cs
- EffectiveValueEntry.cs
- ResourceProperty.cs
- DiscoveryService.cs
- DataRowComparer.cs
- WebPartEditorOkVerb.cs
- _LocalDataStore.cs
- PieceDirectory.cs
- DataBoundControlHelper.cs
- DataSourceSelectArguments.cs
- KerberosTokenFactoryCredential.cs
- OutputScope.cs
- SqlDataSourceSelectingEventArgs.cs
- RegexReplacement.cs
- SizeLimitedCache.cs
- DbDataReader.cs
- SettingsAttributeDictionary.cs
- MetaModel.cs
- mediapermission.cs
- UnsafeNativeMethods.cs
- Int32Converter.cs
- ItemAutomationPeer.cs
- XmlElementAttributes.cs
- AuthenticationException.cs
- Menu.cs
- TextOutput.cs
- AsyncCompletedEventArgs.cs
- SvcMapFileSerializer.cs
- FormsAuthenticationCredentials.cs
- PrivilegeNotHeldException.cs
- ToolboxItemCollection.cs
- ObjectDataSourceChooseTypePanel.cs
- PackagingUtilities.cs
- CompositeScriptReferenceEventArgs.cs
- LogAppendAsyncResult.cs
- ColumnBinding.cs
- ConstructorBuilder.cs
- DeviceSpecific.cs
- EventToken.cs
- InputLanguageSource.cs
- MarkedHighlightComponent.cs
- GlyphTypeface.cs
- TrackingMemoryStream.cs
- SystemIPv4InterfaceProperties.cs
- ImageBrush.cs
- DecimalMinMaxAggregationOperator.cs
- DataViewListener.cs
- DummyDataSource.cs
- InputScope.cs
- JsonObjectDataContract.cs
- Types.cs
- ListItemsCollectionEditor.cs
- TemplateXamlParser.cs
- TableColumn.cs
- DataGridSortCommandEventArgs.cs
- Line.cs
- ComponentEditorForm.cs
- ValidatorAttribute.cs
- DynamicResourceExtensionConverter.cs
- IODescriptionAttribute.cs
- PropertyStore.cs
- NegotiateStream.cs
- ToolStripDropDownMenu.cs
- MethodExpr.cs
- TextAutomationPeer.cs
- NetworkInformationException.cs
- List.cs
- VariableQuery.cs
- SimpleTypeResolver.cs
- BitmapEffectRenderDataResource.cs
- FullTextState.cs
- precedingsibling.cs
- RegionInfo.cs
- DetailsViewRow.cs
- StaticDataManager.cs
- CodePropertyReferenceExpression.cs