Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / Design / NotifyParentPropertyAttribute.cs / 1 / NotifyParentPropertyAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.Property)] public sealed class NotifyParentPropertyAttribute : Attribute { ////// Indicates whether the parent property is notified /// if a child namespace property is modified. /// ////// public static readonly NotifyParentPropertyAttribute Yes = new NotifyParentPropertyAttribute(true); ////// Specifies that the parent property should be notified on changes to the child class property. This field is read-only. /// ////// public static readonly NotifyParentPropertyAttribute No = new NotifyParentPropertyAttribute(false); ///Specifies that the parent property should not be notified of changes to the child class property. This field is read-only. ////// public static readonly NotifyParentPropertyAttribute Default = No; private bool notifyParent = false; ///Specifies the default attribute state, that the parent property should not be notified of changes to the child class property. /// This field is read-only. ////// public NotifyParentPropertyAttribute(bool notifyParent) { this.notifyParent = notifyParent; } ///Initiailzes a new instance of the NotifyPropertyAttribute class /// that uses the specified value /// to indicate whether the parent property should be notified when a child namespace property is modified. ////// public bool NotifyParent { get { return notifyParent; } } ////// Gets or sets whether the parent property should be notified /// on changes to a child namespace property. /// ////// public override bool Equals(object obj) { if (obj == this) { return true; } if ((obj != null) && (obj is NotifyParentPropertyAttribute)) { return ((NotifyParentPropertyAttribute)obj).NotifyParent == notifyParent; } return false; } ////// Tests whether the specified object is the same as the current object. /// ////// public override int GetHashCode() { return base.GetHashCode(); } ////// Returns the hashcode for this object. /// ////// public override bool IsDefaultAttribute() { return this.Equals(Default); } } }/// Gets whether this attribute is ///by default. ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TCPClient.cs
- UncommonField.cs
- HyperlinkAutomationPeer.cs
- Input.cs
- CancellationHandlerDesigner.cs
- FrameworkPropertyMetadata.cs
- RowType.cs
- DashStyle.cs
- NameValueConfigurationCollection.cs
- WorkflowQueue.cs
- OutputCacheModule.cs
- sitestring.cs
- TargetPerspective.cs
- XmlSchemaChoice.cs
- LinqDataSourceInsertEventArgs.cs
- DynamicField.cs
- DataPagerFieldItem.cs
- InternalResources.cs
- UrlPath.cs
- Parameter.cs
- ImageSource.cs
- ElementNotAvailableException.cs
- StyleReferenceConverter.cs
- ScrollViewer.cs
- ExceptionUtil.cs
- TreeBuilder.cs
- BaseDataList.cs
- CodeRemoveEventStatement.cs
- handlecollector.cs
- InstallerTypeAttribute.cs
- EncoderParameter.cs
- TableLayoutColumnStyleCollection.cs
- SplayTreeNode.cs
- Vector.cs
- MessageLoggingElement.cs
- DrawingCollection.cs
- InputQueueChannel.cs
- ProvideValueServiceProvider.cs
- InputLangChangeEvent.cs
- EraserBehavior.cs
- DragStartedEventArgs.cs
- QueryCacheManager.cs
- PseudoWebRequest.cs
- StylusCollection.cs
- IRCollection.cs
- ComplexTypeEmitter.cs
- PasswordPropertyTextAttribute.cs
- ForAllOperator.cs
- SelectingProviderEventArgs.cs
- CLRBindingWorker.cs
- Msmq4PoisonHandler.cs
- TraceLog.cs
- FillBehavior.cs
- ByteStorage.cs
- CroppedBitmap.cs
- FieldNameLookup.cs
- MaskDescriptor.cs
- UserPersonalizationStateInfo.cs
- SchemaElementDecl.cs
- AutoResetEvent.cs
- WindowsEditBoxRange.cs
- List.cs
- DialogResultConverter.cs
- UserNameSecurityTokenAuthenticator.cs
- PolyQuadraticBezierSegment.cs
- HijriCalendar.cs
- MultiplexingDispatchMessageFormatter.cs
- TextEffect.cs
- DBSqlParserTableCollection.cs
- ExponentialEase.cs
- ListViewItem.cs
- DesignerVerbCollection.cs
- BindingContext.cs
- BlobPersonalizationState.cs
- Simplifier.cs
- ItemsPanelTemplate.cs
- CompilationAssemblyInstallComponent.cs
- RuntimeWrappedException.cs
- FixedTextPointer.cs
- XmlImplementation.cs
- ErrorProvider.cs
- XmlSchemaAttributeGroupRef.cs
- DetailsViewRowCollection.cs
- ValueQuery.cs
- OpCodes.cs
- ValidationPropertyAttribute.cs
- HtmlElementCollection.cs
- EventHandlerService.cs
- ExtendedPropertyCollection.cs
- HealthMonitoringSectionHelper.cs
- ElementHostAutomationPeer.cs
- NullableIntMinMaxAggregationOperator.cs
- GPRECT.cs
- ScalarType.cs
- Context.cs
- ComponentCommands.cs
- NameValuePair.cs
- KeyConverter.cs
- DefaultAssemblyResolver.cs
- ClientSettings.cs