Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / LocalizableAttribute.cs / 1305376 / LocalizableAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class LocalizableAttribute : Attribute { private bool isLocalizable = false; ///Specifies whether a property should be localized. ////// public LocalizableAttribute(bool isLocalizable) { this.isLocalizable = isLocalizable; } ////// Initializes a new instance of the ///class. /// /// public bool IsLocalizable { get { return isLocalizable; } } ////// Gets a value indicating whether /// a property should be localized. /// ////// public static readonly LocalizableAttribute Yes = new LocalizableAttribute(true); ////// Specifies that a property should be localized. This /// ///field is read-only. /// /// public static readonly LocalizableAttribute No = new LocalizableAttribute(false); ////// Specifies that a property should not be localized. This /// ///field is read-only. /// /// public static readonly LocalizableAttribute Default = No; ////// Specifies the default value, which is ///, that is /// a property should not be localized. This field is /// read-only. /// /// /// public override bool IsDefaultAttribute() { return (IsLocalizable == Default.IsLocalizable); } public override bool Equals(object obj) { LocalizableAttribute other = obj as LocalizableAttribute; return (other != null) && other.IsLocalizable == this.isLocalizable; } public override int GetHashCode() { return base.GetHashCode(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class LocalizableAttribute : Attribute { private bool isLocalizable = false; ///Specifies whether a property should be localized. ////// public LocalizableAttribute(bool isLocalizable) { this.isLocalizable = isLocalizable; } ////// Initializes a new instance of the ///class. /// /// public bool IsLocalizable { get { return isLocalizable; } } ////// Gets a value indicating whether /// a property should be localized. /// ////// public static readonly LocalizableAttribute Yes = new LocalizableAttribute(true); ////// Specifies that a property should be localized. This /// ///field is read-only. /// /// public static readonly LocalizableAttribute No = new LocalizableAttribute(false); ////// Specifies that a property should not be localized. This /// ///field is read-only. /// /// public static readonly LocalizableAttribute Default = No; ////// Specifies the default value, which is ///, that is /// a property should not be localized. This field is /// read-only. /// /// /// public override bool IsDefaultAttribute() { return (IsLocalizable == Default.IsLocalizable); } public override bool Equals(object obj) { LocalizableAttribute other = obj as LocalizableAttribute; return (other != null) && other.IsLocalizable == this.isLocalizable; } public override int GetHashCode() { return base.GetHashCode(); } } } // 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
- InputBinding.cs
- SectionInput.cs
- WebPartDescription.cs
- DEREncoding.cs
- HandleExceptionArgs.cs
- ResXResourceReader.cs
- ElementHost.cs
- ProtocolsConfigurationEntry.cs
- SubpageParaClient.cs
- RevocationPoint.cs
- BaseCollection.cs
- CodeVariableDeclarationStatement.cs
- ProcessingInstructionAction.cs
- ConstructorNeedsTagAttribute.cs
- ImageIndexConverter.cs
- BaseValidator.cs
- WebReferencesBuildProvider.cs
- TransformValueSerializer.cs
- NativeMethods.cs
- ThreadAbortException.cs
- ProtocolReflector.cs
- TextParagraph.cs
- TimeSpanMinutesOrInfiniteConverter.cs
- TripleDES.cs
- RelationshipConverter.cs
- TypeHelper.cs
- XmlSchemaExternal.cs
- UIElementParagraph.cs
- TextFormatter.cs
- TemplateField.cs
- HelpEvent.cs
- ForeignKeyFactory.cs
- SQLDouble.cs
- StreamResourceInfo.cs
- WindowShowOrOpenTracker.cs
- CardSpaceException.cs
- ActivityExecutorSurrogate.cs
- HyperLink.cs
- Rijndael.cs
- XmlTextReaderImplHelpers.cs
- FontCollection.cs
- List.cs
- CellIdBoolean.cs
- AllMembershipCondition.cs
- DependencyObject.cs
- IItemProperties.cs
- XPathMessageFilter.cs
- HMACSHA512.cs
- Utilities.cs
- SchemaImporterExtensionElement.cs
- XmlBaseWriter.cs
- PhonemeConverter.cs
- MatrixValueSerializer.cs
- ProfileParameter.cs
- DataObjectSettingDataEventArgs.cs
- ActivityPreviewDesigner.cs
- NTAccount.cs
- ContentOperations.cs
- ConsumerConnectionPointCollection.cs
- Bitmap.cs
- WindowsFont.cs
- XPathConvert.cs
- ListViewContainer.cs
- FontWeights.cs
- CodeBinaryOperatorExpression.cs
- ReachNamespaceInfo.cs
- BitmapDownload.cs
- OleDbSchemaGuid.cs
- SecurityTokenProvider.cs
- DoubleAnimationClockResource.cs
- ExpandSegmentCollection.cs
- ConstructorBuilder.cs
- LinqDataSourceInsertEventArgs.cs
- VirtualPathData.cs
- XmlNodeReader.cs
- RangeValidator.cs
- ApplicationSecurityManager.cs
- XslTransform.cs
- MailWriter.cs
- FirstMatchCodeGroup.cs
- ParameterToken.cs
- EventMappingSettingsCollection.cs
- QueryStringHandler.cs
- WindowsNonControl.cs
- X509Certificate2Collection.cs
- Permission.cs
- ExceptionHelpers.cs
- ActiveDocumentEvent.cs
- KeyEventArgs.cs
- Region.cs
- PagesChangedEventArgs.cs
- DataSourceCache.cs
- CuspData.cs
- RTLAwareMessageBox.cs
- UmAlQuraCalendar.cs
- ScrollItemPatternIdentifiers.cs
- HostedBindingBehavior.cs
- DetailsViewDeleteEventArgs.cs
- KeyTime.cs
- WindowsAuthenticationEventArgs.cs