Code:
/ FX-1434 / FX-1434 / 1.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
- XhtmlBasicTextBoxAdapter.cs
- KeyEvent.cs
- PreviousTrackingServiceAttribute.cs
- SQLBytesStorage.cs
- unitconverter.cs
- CheckBox.cs
- DataGridViewToolTip.cs
- AggregateException.cs
- WebBrowserNavigatingEventHandler.cs
- FlatButtonAppearance.cs
- EntityProviderServices.cs
- TableLayoutStyleCollection.cs
- InvariantComparer.cs
- ReturnValue.cs
- DbModificationCommandTree.cs
- HealthMonitoringSectionHelper.cs
- SystemWebExtensionsSectionGroup.cs
- GreenMethods.cs
- StrokeNodeEnumerator.cs
- AdornerPresentationContext.cs
- SerializationException.cs
- ValueUtilsSmi.cs
- TextServicesProperty.cs
- MouseGestureValueSerializer.cs
- FixedDocument.cs
- AutomationProperty.cs
- MachineKeySection.cs
- ToolStripDropDownMenu.cs
- SessionStateContainer.cs
- CuspData.cs
- DesignBindingPropertyDescriptor.cs
- XmlnsDefinitionAttribute.cs
- ComPlusServiceHost.cs
- TableDetailsRow.cs
- Missing.cs
- OperationParameterInfo.cs
- InfoCardRSAPKCS1KeyExchangeFormatter.cs
- TriggerActionCollection.cs
- SiteMapDesignerDataSourceView.cs
- RangeValuePatternIdentifiers.cs
- DataServiceQuery.cs
- Graph.cs
- ServiceProviders.cs
- DataGridBoolColumn.cs
- TraceListener.cs
- InvalidWMPVersionException.cs
- WsdlInspector.cs
- DesignerContextDescriptor.cs
- SpeechUI.cs
- UnsafeNativeMethods.cs
- XmlSchemaIdentityConstraint.cs
- UnsafeNativeMethods.cs
- IndexerNameAttribute.cs
- ConstraintConverter.cs
- DataObject.cs
- SimplePropertyEntry.cs
- AssociationType.cs
- HtmlHead.cs
- DefaultParameterValueAttribute.cs
- CacheForPrimitiveTypes.cs
- BinaryMethodMessage.cs
- TransformedBitmap.cs
- TrustManager.cs
- Model3DGroup.cs
- EntityDataSourceDataSelection.cs
- Operand.cs
- DbParameterHelper.cs
- ObjectQuery.cs
- CompilationRelaxations.cs
- TextParaClient.cs
- CollaborationHelperFunctions.cs
- HeaderCollection.cs
- PenThreadWorker.cs
- SafeNativeHandle.cs
- MeasureData.cs
- SerialErrors.cs
- FixedHyperLink.cs
- DataGridCellsPanel.cs
- PropertyMap.cs
- XmlNodeChangedEventArgs.cs
- TraceEventCache.cs
- KeyedHashAlgorithm.cs
- EmulateRecognizeCompletedEventArgs.cs
- basenumberconverter.cs
- SmtpNtlmAuthenticationModule.cs
- TemplateAction.cs
- WorkflowDefinitionContext.cs
- Soap.cs
- ValueTypeFixupInfo.cs
- DrawingVisualDrawingContext.cs
- dataprotectionpermission.cs
- SvcMapFile.cs
- DbParameterHelper.cs
- BitmapEffect.cs
- ClientBuildManager.cs
- DBConnectionString.cs
- IPAddressCollection.cs
- FrameworkElement.cs
- WindowsFormsEditorServiceHelper.cs
- NetworkInformationException.cs