Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / DescriptionAttribute.cs / 1 / DescriptionAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public class DescriptionAttribute : Attribute { ///Specifies a description for a property /// or event. ////// public static readonly DescriptionAttribute Default = new DescriptionAttribute(); private string description; ///Specifies the default value for the ///, which is an /// empty string (""). This field is read-only. /// public DescriptionAttribute() : this (string.Empty) { } ///[To be supplied.] ////// public DescriptionAttribute(string description) { this.description = description; } ///Initializes a new instance of the ///class. /// public virtual string Description { get { return DescriptionValue; } } ///Gets the description stored in this attribute. ////// Read/Write property that directly modifies the string stored /// in the description attribute. The default implementation /// of the Description property simply returns this value. /// protected string DescriptionValue { get { return description; } set { description = value; } } public override bool Equals(object obj) { if (obj == this) { return true; } DescriptionAttribute other = obj as DescriptionAttribute; return (other != null) && other.Description == Description; } public override int GetHashCode() { return Description.GetHashCode(); } ////// /// public override bool IsDefaultAttribute() { return (this.Equals(Default)); } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebEventCodes.cs
- StorageEndPropertyMapping.cs
- EncoderNLS.cs
- FlowNode.cs
- Rotation3DKeyFrameCollection.cs
- AttributeParameterInfo.cs
- SqlCacheDependencySection.cs
- HtmlElementErrorEventArgs.cs
- DataTableNewRowEvent.cs
- TypeNameConverter.cs
- SimpleWebHandlerParser.cs
- PixelShader.cs
- CodeThrowExceptionStatement.cs
- ToolStripButton.cs
- SuppressMessageAttribute.cs
- JoinTreeSlot.cs
- SafeNativeMethods.cs
- AnnouncementEndpointElement.cs
- TemplatedAdorner.cs
- PackageRelationship.cs
- XmlComplianceUtil.cs
- RegistryKey.cs
- TypeConverter.cs
- TableRow.cs
- IntSecurity.cs
- Int32AnimationUsingKeyFrames.cs
- SspiSecurityToken.cs
- EventTrigger.cs
- OverflowException.cs
- SchemaImporter.cs
- EventHandlerList.cs
- EdmItemCollection.cs
- CodePageUtils.cs
- PageOrientation.cs
- SqlUtil.cs
- GlyphingCache.cs
- SelectionRangeConverter.cs
- DecimalAnimationUsingKeyFrames.cs
- MexHttpBindingCollectionElement.cs
- XmlAnyElementAttributes.cs
- HtmlTableRowCollection.cs
- SqlLiftIndependentRowExpressions.cs
- PropertySourceInfo.cs
- DataGridViewColumnCollectionDialog.cs
- ControlParameter.cs
- PingReply.cs
- DataPager.cs
- ReceiveDesigner.xaml.cs
- Size3D.cs
- DSASignatureDeformatter.cs
- CultureInfo.cs
- StrongNamePublicKeyBlob.cs
- TimerElapsedEvenArgs.cs
- ResourceDictionaryCollection.cs
- Vector.cs
- FormatterServices.cs
- InternalPermissions.cs
- ResizingMessageFilter.cs
- GridViewColumnHeaderAutomationPeer.cs
- WebScriptMetadataMessageEncodingBindingElement.cs
- ClassDataContract.cs
- UserInitiatedNavigationPermission.cs
- HtmlTableCellCollection.cs
- FixedSOMTableCell.cs
- FunctionCommandText.cs
- AuthorizationRuleCollection.cs
- CroppedBitmap.cs
- CatchBlock.cs
- RestClientProxyHandler.cs
- ListViewGroupCollectionEditor.cs
- IisNotInstalledException.cs
- BitArray.cs
- TextTreeRootTextBlock.cs
- TouchesCapturedWithinProperty.cs
- BounceEase.cs
- HwndHost.cs
- lengthconverter.cs
- Expression.cs
- AbstractExpressions.cs
- EmissiveMaterial.cs
- ParseChildrenAsPropertiesAttribute.cs
- MetabaseServerConfig.cs
- MessageEncoder.cs
- DictationGrammar.cs
- Paragraph.cs
- ClassDataContract.cs
- ReadOnlyPropertyMetadata.cs
- ThreadStartException.cs
- TableLayoutCellPaintEventArgs.cs
- CuspData.cs
- DataGridViewDataErrorEventArgs.cs
- TextBlockAutomationPeer.cs
- HtmlHistory.cs
- ComUdtElementCollection.cs
- Help.cs
- XmlSchemaImport.cs
- VisualTreeUtils.cs
- CodeVariableDeclarationStatement.cs
- SqlDataSourceStatusEventArgs.cs
- RuleProcessor.cs