Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / 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
- HostingEnvironment.cs
- ProtocolReflector.cs
- ConsumerConnectionPointCollection.cs
- DataGridViewBand.cs
- SerializationInfo.cs
- InOutArgumentConverter.cs
- TextTreeExtractElementUndoUnit.cs
- CompositionAdorner.cs
- GraphicsPath.cs
- ProgressPage.cs
- InitializingNewItemEventArgs.cs
- HtmlInputFile.cs
- CustomErrorsSectionWrapper.cs
- StateMachine.cs
- NativeWindow.cs
- TailPinnedEventArgs.cs
- WebServiceAttribute.cs
- UpDownBase.cs
- TreeWalkHelper.cs
- HtmlHead.cs
- TextReturnReader.cs
- SamlAuthorityBinding.cs
- BindMarkupExtensionSerializer.cs
- SchemaLookupTable.cs
- DynamicILGenerator.cs
- TdsParserStateObject.cs
- DefaultSerializationProviderAttribute.cs
- SoapRpcServiceAttribute.cs
- PropertyValueUIItem.cs
- AlignmentXValidation.cs
- AnimationClock.cs
- DescendantBaseQuery.cs
- ApplicationSecurityInfo.cs
- CookieHandler.cs
- DoubleLinkList.cs
- SHA384.cs
- LiteralControl.cs
- EncryptedPackageFilter.cs
- DiagnosticEventProvider.cs
- DefaultMemberAttribute.cs
- PeerContact.cs
- CommonObjectSecurity.cs
- WpfPayload.cs
- SystemSounds.cs
- VarRemapper.cs
- EncryptedKey.cs
- ProfileManager.cs
- DocumentsTrace.cs
- SQLString.cs
- WebPartCatalogCloseVerb.cs
- BezierSegment.cs
- XmlQueryTypeFactory.cs
- WebZone.cs
- Base64Decoder.cs
- FixedTextView.cs
- codemethodreferenceexpression.cs
- PipeStream.cs
- InkCanvasSelectionAdorner.cs
- MaterialGroup.cs
- WhereQueryOperator.cs
- DataRelationPropertyDescriptor.cs
- WebPartCollection.cs
- ImageMetadata.cs
- UnmanagedMemoryStream.cs
- UserMapPath.cs
- KeyValuePair.cs
- ArraySortHelper.cs
- HtmlInputControl.cs
- SvcMapFileSerializer.cs
- AxisAngleRotation3D.cs
- FixedHyperLink.cs
- ThaiBuddhistCalendar.cs
- MetafileHeaderWmf.cs
- SingleTagSectionHandler.cs
- SpoolingTask.cs
- RegexMatch.cs
- MethodRental.cs
- StyleCollection.cs
- FormsAuthenticationConfiguration.cs
- TraceXPathNavigator.cs
- DataGridViewImageCell.cs
- WebPartAddingEventArgs.cs
- ReferencedAssembly.cs
- WebBrowserProgressChangedEventHandler.cs
- TypeConverterHelper.cs
- CatchDesigner.xaml.cs
- _IPv4Address.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- VisualStyleElement.cs
- IdentityManager.cs
- MapPathBasedVirtualPathProvider.cs
- DataGridViewEditingControlShowingEventArgs.cs
- PreservationFileWriter.cs
- DataKey.cs
- ScrollBarRenderer.cs
- SqlDataRecord.cs
- MenuDesigner.cs
- WebBrowserBase.cs
- MessageBox.cs
- XmlBaseWriter.cs