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
- EnvelopedPkcs7.cs
- SmiMetaDataProperty.cs
- Animatable.cs
- GlobalProxySelection.cs
- GridViewUpdateEventArgs.cs
- XPathSelectionIterator.cs
- ApplicationProxyInternal.cs
- HandlerBase.cs
- PriorityChain.cs
- LockCookie.cs
- WebPartChrome.cs
- SmtpNegotiateAuthenticationModule.cs
- AppDomainAttributes.cs
- Tuple.cs
- GroupJoinQueryOperator.cs
- IpcManager.cs
- RuleDefinitions.cs
- SocketInformation.cs
- UnsafeNetInfoNativeMethods.cs
- FlowDocumentReaderAutomationPeer.cs
- ISCIIEncoding.cs
- ReadOnlyState.cs
- ScopelessEnumAttribute.cs
- AdRotatorDesigner.cs
- SecurityContextTokenValidationException.cs
- FileLoadException.cs
- AggregateNode.cs
- ToolStripOverflowButton.cs
- MediaPlayerState.cs
- ISAPIWorkerRequest.cs
- CategoryAttribute.cs
- BamlVersionHeader.cs
- LinkArea.cs
- WebConfigurationFileMap.cs
- AbsoluteQuery.cs
- VoiceObjectToken.cs
- DependencySource.cs
- TypedDataSourceCodeGenerator.cs
- IncomingWebRequestContext.cs
- Column.cs
- VariableQuery.cs
- RC2.cs
- DtdParser.cs
- GotoExpression.cs
- ScriptHandlerFactory.cs
- DataGridViewTextBoxEditingControl.cs
- RC2.cs
- DbCommandDefinition.cs
- PowerStatus.cs
- XmlILOptimizerVisitor.cs
- SoapInteropTypes.cs
- XmlSchemas.cs
- MsmqIntegrationMessageProperty.cs
- AutoGeneratedField.cs
- SamlAuthenticationClaimResource.cs
- Endpoint.cs
- NegationPusher.cs
- KeyedCollection.cs
- AesCryptoServiceProvider.cs
- OleDbCommandBuilder.cs
- AssemblyCollection.cs
- WindowsStatusBar.cs
- DNS.cs
- KeyboardNavigation.cs
- TemplatedAdorner.cs
- ADMembershipProvider.cs
- DataControlFieldCell.cs
- WaitHandleCannotBeOpenedException.cs
- ping.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- RowParagraph.cs
- DataSysAttribute.cs
- ClosableStream.cs
- FrameworkContextData.cs
- TreeBuilderBamlTranslator.cs
- FormViewInsertedEventArgs.cs
- DropTarget.cs
- PerfService.cs
- GeneratedView.cs
- DataGridViewUtilities.cs
- EdmPropertyAttribute.cs
- QilTernary.cs
- TextTreeInsertElementUndoUnit.cs
- XamlStackWriter.cs
- CfgParser.cs
- GridViewCellAutomationPeer.cs
- TextCompositionEventArgs.cs
- DateTimeSerializationSection.cs
- CacheEntry.cs
- FlowDocument.cs
- ColorDialog.cs
- PointF.cs
- SessionEndedEventArgs.cs
- XmlDictionaryReader.cs
- PropertyPathWorker.cs
- VarRemapper.cs
- DetailsViewModeEventArgs.cs
- GradientBrush.cs
- RotateTransform.cs
- DbCommandDefinition.cs