Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / DefaultPropertyAttribute.cs / 1305376 / DefaultPropertyAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.Class)] public sealed class DefaultPropertyAttribute : Attribute { ///Specifies the default property for a component. ////// This is the default event name. /// private readonly string name; ////// public DefaultPropertyAttribute(string name) { this.name = name; } ////// Initializes a new instance of /// the ///class. /// /// public string Name { get { return name; } } ////// Gets the name of the default property for the component this attribute is /// bound to. /// ////// public static readonly DefaultPropertyAttribute Default = new DefaultPropertyAttribute(null); public override bool Equals(object obj) { DefaultPropertyAttribute other = obj as DefaultPropertyAttribute; return (other != null) && other.Name == name; } public override int GetHashCode() { return base.GetHashCode(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ ///// Specifies the default value for the ///, which is . This /// field is read-only. /// // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.Class)] public sealed class DefaultPropertyAttribute : Attribute { ///Specifies the default property for a component. ////// This is the default event name. /// private readonly string name; ////// public DefaultPropertyAttribute(string name) { this.name = name; } ////// Initializes a new instance of /// the ///class. /// /// public string Name { get { return name; } } ////// Gets the name of the default property for the component this attribute is /// bound to. /// ////// public static readonly DefaultPropertyAttribute Default = new DefaultPropertyAttribute(null); public override bool Equals(object obj) { DefaultPropertyAttribute other = obj as DefaultPropertyAttribute; return (other != null) && other.Name == name; } public override int GetHashCode() { return base.GetHashCode(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007./// Specifies the default value for the ///, which is . This /// field is read-only. ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- PlaceHolder.cs
- BaseDataList.cs
- XmlHierarchicalDataSourceView.cs
- WebPartsPersonalizationAuthorization.cs
- PathFigureCollection.cs
- ButtonBaseAdapter.cs
- EntityTransaction.cs
- SystemInfo.cs
- ScalarType.cs
- TimeSpanValidatorAttribute.cs
- ElapsedEventArgs.cs
- ObjectHelper.cs
- ContentType.cs
- StylusTouchDevice.cs
- HelpInfo.cs
- EncryptedKey.cs
- RelatedCurrencyManager.cs
- EntityKeyElement.cs
- Pair.cs
- Gdiplus.cs
- LocatorManager.cs
- IncrementalReadDecoders.cs
- UiaCoreProviderApi.cs
- SerialPinChanges.cs
- SafeRightsManagementQueryHandle.cs
- MetadataArtifactLoader.cs
- WebPartZone.cs
- DataService.cs
- LinqDataView.cs
- TextBox.cs
- JournalEntryStack.cs
- ListControlConvertEventArgs.cs
- SpeakCompletedEventArgs.cs
- VoiceChangeEventArgs.cs
- AuditLog.cs
- IISMapPath.cs
- XmlTextReader.cs
- SspiWrapper.cs
- DrawingImage.cs
- HtmlInputButton.cs
- XmlSerializationWriter.cs
- ExcludePathInfo.cs
- RowToParametersTransformer.cs
- GroupItem.cs
- SchemaCollectionCompiler.cs
- Canvas.cs
- DataGridState.cs
- RemoteHelper.cs
- Scene3D.cs
- SymbolDocumentInfo.cs
- EpmSyndicationContentSerializer.cs
- ViewgenContext.cs
- DisableDpiAwarenessAttribute.cs
- SimpleMailWebEventProvider.cs
- FragmentQueryKB.cs
- WindowClosedEventArgs.cs
- FileLogRecord.cs
- DrawingGroupDrawingContext.cs
- AmbiguousMatchException.cs
- SystemWebCachingSectionGroup.cs
- ZipIOExtraFieldPaddingElement.cs
- Byte.cs
- SafeSerializationManager.cs
- MetadataPropertyAttribute.cs
- XmlSignatureProperties.cs
- DataBindingExpressionBuilder.cs
- DataTableCollection.cs
- Int32Collection.cs
- FontSourceCollection.cs
- TagMapInfo.cs
- Soap12FormatExtensions.cs
- DataGridViewRowHeaderCell.cs
- FileDialog_Vista.cs
- ContentPropertyAttribute.cs
- AsyncPostBackErrorEventArgs.cs
- CounterCreationDataCollection.cs
- xsdvalidator.cs
- MetadataSource.cs
- FormatConvertedBitmap.cs
- CachedTypeface.cs
- MessagingDescriptionAttribute.cs
- ProcessStartInfo.cs
- CanonicalFontFamilyReference.cs
- MessageDirection.cs
- MarkupCompiler.cs
- Vertex.cs
- InternalConfigSettingsFactory.cs
- KeyValuePair.cs
- AssemblyAssociatedContentFileAttribute.cs
- QueryStringHandler.cs
- NetworkInterface.cs
- StringAnimationUsingKeyFrames.cs
- ExcCanonicalXml.cs
- SoundPlayer.cs
- RoleManagerEventArgs.cs
- ShimAsPublicXamlType.cs
- shaperfactoryquerycacheentry.cs
- BrowsableAttribute.cs
- GestureRecognitionResult.cs
- SocketPermission.cs