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
- SystemTcpConnection.cs
- TextRangeAdaptor.cs
- ToolboxControl.cs
- SessionStateItemCollection.cs
- PasswordTextNavigator.cs
- SoapCodeExporter.cs
- NumericUpDown.cs
- PKCS1MaskGenerationMethod.cs
- SqlConnectionString.cs
- ScrollableControl.cs
- ProxyWebPart.cs
- BamlLocalizer.cs
- FormViewPagerRow.cs
- ViewGenerator.cs
- WindowAutomationPeer.cs
- AnnotationService.cs
- Sentence.cs
- SchemaTableColumn.cs
- UInt16Storage.cs
- StorageEntityTypeMapping.cs
- OrderToken.cs
- RelationshipConverter.cs
- CommandTreeTypeHelper.cs
- SerializationSectionGroup.cs
- RtfControlWordInfo.cs
- HtmlButton.cs
- TransactedReceiveData.cs
- HandleValueEditor.cs
- ByteConverter.cs
- XsltException.cs
- DependentList.cs
- TypeNameHelper.cs
- HostProtectionPermission.cs
- IgnoreSectionHandler.cs
- RC2CryptoServiceProvider.cs
- regiisutil.cs
- WindowsPen.cs
- MimeTypeAttribute.cs
- _AutoWebProxyScriptHelper.cs
- DbBuffer.cs
- ServicesExceptionNotHandledEventArgs.cs
- WebPartMenu.cs
- DataGridViewCellFormattingEventArgs.cs
- CursorInteropHelper.cs
- CacheDict.cs
- MemoryMappedViewStream.cs
- SqlBuilder.cs
- ContractMapping.cs
- DetailsViewRow.cs
- EventsTab.cs
- DoubleAnimationUsingPath.cs
- DecoderReplacementFallback.cs
- OdbcPermission.cs
- Point3DCollection.cs
- LoginDesignerUtil.cs
- CreateUserWizardStep.cs
- NativeMethods.cs
- PlatformNotSupportedException.cs
- GeneralTransform.cs
- TextCompositionEventArgs.cs
- CaretElement.cs
- TypeResolver.cs
- GlyphRunDrawing.cs
- XmlSchemaAny.cs
- ResourceContainer.cs
- DrawingGroup.cs
- ApplicationBuildProvider.cs
- SelectionService.cs
- CodeDelegateCreateExpression.cs
- CodeTypeReferenceExpression.cs
- DataGridCaption.cs
- Object.cs
- HwndSourceParameters.cs
- TextAdaptor.cs
- LogAppendAsyncResult.cs
- assertwrapper.cs
- KeyBinding.cs
- XamlValidatingReader.cs
- AlphabeticalEnumConverter.cs
- UserControlFileEditor.cs
- Assert.cs
- ErrorRuntimeConfig.cs
- SpanIndex.cs
- XPathNode.cs
- ClientConfigurationSystem.cs
- PathGradientBrush.cs
- NavigationProperty.cs
- SendOperation.cs
- EnumUnknown.cs
- CroppedBitmap.cs
- EntityDataSourceContextCreatingEventArgs.cs
- MultiPageTextView.cs
- X509CertificateClaimSet.cs
- DBConnection.cs
- RenderingEventArgs.cs
- HttpResponseWrapper.cs
- ResXResourceReader.cs
- BufferModeSettings.cs
- UseManagedPresentationBindingElementImporter.cs
- ToolStripSplitStackLayout.cs