Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / CompMod / System / ComponentModel / DefaultPropertyAttribute.cs / 1 / 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
- ClockGroup.cs
- Byte.cs
- OpenTypeLayoutCache.cs
- EventBookmark.cs
- PrimaryKeyTypeConverter.cs
- StaticSiteMapProvider.cs
- CodeAttachEventStatement.cs
- ComEventsMethod.cs
- WpfWebRequestHelper.cs
- RouteData.cs
- GraphicsPathIterator.cs
- ResourceManagerWrapper.cs
- HttpRequest.cs
- HttpFileCollection.cs
- ProxyFragment.cs
- OrderingQueryOperator.cs
- GlyphRunDrawing.cs
- KnownBoxes.cs
- SystemNetHelpers.cs
- AncestorChangedEventArgs.cs
- _Semaphore.cs
- DynamicPropertyHolder.cs
- DuplicateWaitObjectException.cs
- Parameter.cs
- ActivityExecutionContext.cs
- SerializableAttribute.cs
- ConfigurationSettings.cs
- StreamReader.cs
- PeerCredentialElement.cs
- Query.cs
- LOSFormatter.cs
- DesignerDataTable.cs
- PerfService.cs
- SqlCommandSet.cs
- ConfigurationManager.cs
- CommonXSendMessage.cs
- InputElement.cs
- TableCell.cs
- TextPatternIdentifiers.cs
- DefinitionUpdate.cs
- PenThread.cs
- EditorPartCollection.cs
- ObjectConverter.cs
- CachingHintValidation.cs
- SQLDouble.cs
- RangeValueProviderWrapper.cs
- AttachedPropertyBrowsableWhenAttributePresentAttribute.cs
- StrongNamePublicKeyBlob.cs
- CustomAttribute.cs
- ResponseBodyWriter.cs
- ActiveXHost.cs
- ToolStripPanelRow.cs
- SafeNativeMethods.cs
- CodeRemoveEventStatement.cs
- PlainXmlSerializer.cs
- URLEditor.cs
- ConstructorExpr.cs
- DiagnosticsConfigurationHandler.cs
- DupHandleConnectionReader.cs
- XPathExpr.cs
- InvalidBodyAccessException.cs
- MergeLocalizationDirectives.cs
- RsaKeyIdentifierClause.cs
- _ConnectionGroup.cs
- NGCPageContentCollectionSerializerAsync.cs
- ProvidersHelper.cs
- BrowserCapabilitiesFactoryBase.cs
- ScaleTransform.cs
- HttpCacheParams.cs
- WebPartCancelEventArgs.cs
- Viewport3DVisual.cs
- X509CertificateTrustedIssuerElement.cs
- ParameterCollectionEditorForm.cs
- PreservationFileWriter.cs
- PolicyException.cs
- PrimaryKeyTypeConverter.cs
- PageOutputQuality.cs
- ListViewDeletedEventArgs.cs
- UndoUnit.cs
- OdbcCommand.cs
- oledbmetadatacolumnnames.cs
- Thickness.cs
- JpegBitmapEncoder.cs
- XmlSchemaSimpleType.cs
- ComplexTypeEmitter.cs
- SessionMode.cs
- AttributeConverter.cs
- ToolStripDropDown.cs
- HuffCodec.cs
- NumberSubstitution.cs
- IncrementalHitTester.cs
- UpdateCommand.cs
- Message.cs
- Container.cs
- SafeNativeMethodsCLR.cs
- CancellationTokenSource.cs
- DiscoveryDocumentReference.cs
- SctClaimSerializer.cs
- FixedStringLookup.cs
- MaskedTextBox.cs