Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / Design / NotifyParentPropertyAttribute.cs / 1305376 / 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); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007./// Gets whether this attribute is ///by default. ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ContextCorrelationInitializer.cs
- DataGridViewRowContextMenuStripNeededEventArgs.cs
- QuarticEase.cs
- DispatchChannelSink.cs
- SafeFindHandle.cs
- SqlVisitor.cs
- SerializationAttributes.cs
- GenericRootAutomationPeer.cs
- CounterSampleCalculator.cs
- ElementInit.cs
- HebrewCalendar.cs
- BamlLocalizableResourceKey.cs
- LoginUtil.cs
- ProfilePropertySettings.cs
- OutputScopeManager.cs
- EventProxy.cs
- LabelAutomationPeer.cs
- VisualStyleInformation.cs
- HuffCodec.cs
- WebServiceErrorEvent.cs
- MemberInfoSerializationHolder.cs
- InfoCardAsymmetricCrypto.cs
- Menu.cs
- NonBatchDirectoryCompiler.cs
- IncrementalReadDecoders.cs
- SecuritySessionClientSettings.cs
- CheckableControlBaseAdapter.cs
- MaskedTextProvider.cs
- RemoteWebConfigurationHostStream.cs
- CodeCatchClauseCollection.cs
- InvokeAction.cs
- EnumMemberAttribute.cs
- ClosableStream.cs
- AuthenticationManager.cs
- CompilerCollection.cs
- WindowProviderWrapper.cs
- BoundColumn.cs
- Context.cs
- MessageBox.cs
- ClonableStack.cs
- WindowsListViewScroll.cs
- VariableModifiersHelper.cs
- BamlRecordWriter.cs
- SafeRegistryKey.cs
- SessionParameter.cs
- NativeMethods.cs
- IntPtr.cs
- PathTooLongException.cs
- TextEndOfParagraph.cs
- EllipseGeometry.cs
- ScaleTransform.cs
- RSAPKCS1SignatureFormatter.cs
- TextServicesCompartment.cs
- PngBitmapEncoder.cs
- SerialErrors.cs
- FieldValue.cs
- LinkedResource.cs
- NavigationFailedEventArgs.cs
- ReadOnlyDataSource.cs
- MustUnderstandSoapException.cs
- PropertyNames.cs
- CookielessHelper.cs
- RouteItem.cs
- SizeConverter.cs
- FormViewRow.cs
- AdCreatedEventArgs.cs
- UnsafeNativeMethods.cs
- ComAdminWrapper.cs
- DocumentationServerProtocol.cs
- Selection.cs
- SelectionProcessor.cs
- WS2007FederationHttpBindingCollectionElement.cs
- TypedElement.cs
- CancelRequestedQuery.cs
- VirtualPathData.cs
- KeySplineConverter.cs
- DataControlPagerLinkButton.cs
- TemplateManager.cs
- WaitingCursor.cs
- IWorkflowDebuggerService.cs
- DbQueryCommandTree.cs
- DefaultEvaluationContext.cs
- UniqueID.cs
- HttpHandlerAction.cs
- TdsEnums.cs
- NamespaceCollection.cs
- XhtmlBasicValidatorAdapter.cs
- SpeechEvent.cs
- TableStyle.cs
- PeerContact.cs
- DrawingCollection.cs
- GeometryCombineModeValidation.cs
- SystemWebCachingSectionGroup.cs
- ColorAnimationBase.cs
- DataContractAttribute.cs
- NTAccount.cs
- LineProperties.cs
- SizeKeyFrameCollection.cs
- BitmapImage.cs
- SystemWebCachingSectionGroup.cs