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
- SettingsBase.cs
- HandlerFactoryCache.cs
- SettingsProviderCollection.cs
- AttachedPropertyMethodSelector.cs
- NotifyIcon.cs
- CodeArrayCreateExpression.cs
- FlowDocumentScrollViewer.cs
- DecoderReplacementFallback.cs
- ButtonBase.cs
- FormatterServicesNoSerializableCheck.cs
- ListManagerBindingsCollection.cs
- TransformerInfo.cs
- OleDbInfoMessageEvent.cs
- XmlSchemaSet.cs
- ParserStreamGeometryContext.cs
- GenerateScriptTypeAttribute.cs
- PermissionToken.cs
- ExecutionEngineException.cs
- MLangCodePageEncoding.cs
- DataColumnMapping.cs
- XhtmlBasicPanelAdapter.cs
- MimeParameters.cs
- TabPage.cs
- Literal.cs
- VirtualDirectoryMappingCollection.cs
- OciEnlistContext.cs
- CodeSnippetTypeMember.cs
- EntitySet.cs
- PageRanges.cs
- TaskFormBase.cs
- ClientBuildManagerTypeDescriptionProviderBridge.cs
- AttributeAction.cs
- ParameterToken.cs
- BufferedGraphicsManager.cs
- WebBrowserProgressChangedEventHandler.cs
- AspNetSynchronizationContext.cs
- LinkLabel.cs
- FontFamily.cs
- ContractValidationHelper.cs
- HtmlInputSubmit.cs
- LinearGradientBrush.cs
- BitmapSizeOptions.cs
- DefaultParameterValueAttribute.cs
- Tuple.cs
- OleDbFactory.cs
- CopyOfAction.cs
- SHA1CryptoServiceProvider.cs
- WebPartTracker.cs
- ProfessionalColors.cs
- HttpDigestClientCredential.cs
- EmptyImpersonationContext.cs
- GenericQueueSurrogate.cs
- remotingproxy.cs
- BinaryUtilClasses.cs
- ParallelTimeline.cs
- DefaultClaimSet.cs
- Button.cs
- _ConnectOverlappedAsyncResult.cs
- HttpApplication.cs
- Positioning.cs
- altserialization.cs
- SortAction.cs
- FunctionMappingTranslator.cs
- RenderCapability.cs
- GradientBrush.cs
- mil_sdk_version.cs
- DataGridViewSelectedRowCollection.cs
- QilStrConcatenator.cs
- DictionarySurrogate.cs
- TextBounds.cs
- TypefaceCollection.cs
- SqlDependencyUtils.cs
- TextBoxAutomationPeer.cs
- TextDecorationCollectionConverter.cs
- ContentElementAutomationPeer.cs
- Style.cs
- SAPIEngineTypes.cs
- TreeNodeCollectionEditor.cs
- AudioException.cs
- DetailsViewUpdateEventArgs.cs
- EventSinkHelperWriter.cs
- SchemaReference.cs
- MetadataStore.cs
- IgnoreFlushAndCloseStream.cs
- Int16.cs
- MemberProjectionIndex.cs
- ImageAttributes.cs
- BrushMappingModeValidation.cs
- SamlNameIdentifierClaimResource.cs
- QuestionEventArgs.cs
- StorageMappingItemCollection.cs
- CallContext.cs
- safemediahandle.cs
- HttpApplicationFactory.cs
- SimpleHandlerFactory.cs
- SelectedDatesCollection.cs
- System.Data_BID.cs
- XmlSchemaExporter.cs
- ProfileSection.cs
- ColorPalette.cs