Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / DescriptionAttribute.cs / 1305376 / 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(); } #if !SILVERLIGHT ////// /// public override bool IsDefaultAttribute() { return (this.Equals(Default)); } #endif } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RadioButton.cs
- GPRECTF.cs
- Int16Animation.cs
- JavascriptXmlWriterWrapper.cs
- WorkflowServiceBuildProvider.cs
- SequentialUshortCollection.cs
- XmlProcessingInstruction.cs
- OpCopier.cs
- SystemIPInterfaceStatistics.cs
- KnownTypes.cs
- VectorCollectionConverter.cs
- EntityCodeGenerator.cs
- TrackBar.cs
- XPSSignatureDefinition.cs
- KeyboardInputProviderAcquireFocusEventArgs.cs
- Vector3DCollection.cs
- PropertyGrid.cs
- XmlNavigatorStack.cs
- Stylesheet.cs
- EncoderFallback.cs
- RedistVersionInfo.cs
- AudioFormatConverter.cs
- DataSourceProvider.cs
- InternalMappingException.cs
- AutomationPatternInfo.cs
- unitconverter.cs
- NumberFormatInfo.cs
- InputLanguageSource.cs
- PeerNode.cs
- AttributeConverter.cs
- processwaithandle.cs
- Range.cs
- DtdParser.cs
- SoundPlayer.cs
- DistinctQueryOperator.cs
- SqlDelegatedTransaction.cs
- MediaEntryAttribute.cs
- TextBox.cs
- ProvideValueServiceProvider.cs
- Compiler.cs
- EnvironmentPermission.cs
- HtmlDocument.cs
- SessionConnectionReader.cs
- IsolatedStorageFilePermission.cs
- EdgeModeValidation.cs
- MemberCollection.cs
- Rectangle.cs
- SetterBase.cs
- DelegateBodyWriter.cs
- Utils.cs
- ContentType.cs
- CustomPopupPlacement.cs
- CodeBlockBuilder.cs
- WebMessageFormatHelper.cs
- ImageBrush.cs
- ValueProviderWrapper.cs
- ServerType.cs
- Serializer.cs
- ComponentEditorPage.cs
- ServerValidateEventArgs.cs
- TargetParameterCountException.cs
- CustomAssemblyResolver.cs
- SoapElementAttribute.cs
- ActivityPropertyReference.cs
- GPPOINT.cs
- DbExpressionRules.cs
- SqlDataSourceWizardForm.cs
- MenuItem.cs
- TrackingParameters.cs
- AutomationPatternInfo.cs
- PathParser.cs
- FormsAuthenticationEventArgs.cs
- AbsoluteQuery.cs
- PrintControllerWithStatusDialog.cs
- ApplicationSettingsBase.cs
- ByteArrayHelperWithString.cs
- COSERVERINFO.cs
- MemoryMappedFile.cs
- Label.cs
- DefaultIfEmptyQueryOperator.cs
- SequentialWorkflowHeaderFooter.cs
- CodeExporter.cs
- GroupItemAutomationPeer.cs
- mansign.cs
- PropertyBuilder.cs
- AddInProcess.cs
- XmlDataImplementation.cs
- _Rfc2616CacheValidators.cs
- PieceNameHelper.cs
- ListMarkerLine.cs
- ProcessModule.cs
- TargetParameterCountException.cs
- MetadataSource.cs
- DecimalAnimationUsingKeyFrames.cs
- EnvironmentPermission.cs
- PieceDirectory.cs
- AccessDataSource.cs
- ExtensionQuery.cs
- RadioButtonList.cs
- PagedControl.cs