Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / CompMod / System / ComponentModel / LocalizableAttribute.cs / 1 / 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
- ScalarOps.cs
- BuildProvider.cs
- EntitySqlQueryBuilder.cs
- AddInProcess.cs
- NumberSubstitution.cs
- NonceCache.cs
- DataGridViewComboBoxColumn.cs
- cookie.cs
- UIAgentAsyncEndRequest.cs
- GatewayDefinition.cs
- SamlAudienceRestrictionCondition.cs
- HttpClientCertificate.cs
- ServiceTimeoutsBehavior.cs
- InheritanceUI.cs
- XmlSchemaSimpleTypeUnion.cs
- ButtonBaseAdapter.cs
- DataViewSetting.cs
- SqlEnums.cs
- PermissionSetTriple.cs
- SymbolEqualComparer.cs
- CacheMemory.cs
- ResponseBodyWriter.cs
- XmlQueryContext.cs
- ApplicationException.cs
- SafeSecurityHelper.cs
- CryptoHelper.cs
- ResourcePermissionBaseEntry.cs
- TextElementEnumerator.cs
- FileDialog.cs
- DoubleUtil.cs
- arc.cs
- InfoCardServiceInstallComponent.cs
- RootBrowserWindow.cs
- WebPartConnectionsConnectVerb.cs
- BorderGapMaskConverter.cs
- ProvideValueServiceProvider.cs
- DesigntimeLicenseContext.cs
- Brushes.cs
- HyperLinkDesigner.cs
- ParamArrayAttribute.cs
- Translator.cs
- ForeignKeyConstraint.cs
- AnimationException.cs
- Evidence.cs
- DesignTimeSiteMapProvider.cs
- ResponseBodyWriter.cs
- MediaContext.cs
- SafeNativeMethods.cs
- FixedSOMLineRanges.cs
- SyndicationSerializer.cs
- CalendarBlackoutDatesCollection.cs
- InheritanceContextChangedEventManager.cs
- ContentElementAutomationPeer.cs
- ClientSettingsSection.cs
- TraceXPathNavigator.cs
- HierarchicalDataBoundControl.cs
- WorkItem.cs
- DocumentApplication.cs
- DataControlLinkButton.cs
- OptimizedTemplateContent.cs
- DefaultPropertyAttribute.cs
- GridViewColumn.cs
- HelpEvent.cs
- ExpressionVisitorHelpers.cs
- AmbiguousMatchException.cs
- Menu.cs
- MenuDesigner.cs
- MethodExpr.cs
- Profiler.cs
- CrossAppDomainChannel.cs
- SQLInt32Storage.cs
- EventEntry.cs
- RowParagraph.cs
- ScrollViewerAutomationPeer.cs
- MatchingStyle.cs
- GridViewColumnHeaderAutomationPeer.cs
- SemanticValue.cs
- BamlBinaryWriter.cs
- Module.cs
- NonVisualControlAttribute.cs
- WindowsButton.cs
- ObjectDisposedException.cs
- HttpHandlerActionCollection.cs
- RegisterInfo.cs
- TrustManager.cs
- WindowsClaimSet.cs
- AlignmentXValidation.cs
- ContextMenuAutomationPeer.cs
- SettingsProviderCollection.cs
- TextElement.cs
- ThreadInterruptedException.cs
- PropertyFilter.cs
- AutomationFocusChangedEventArgs.cs
- UrlPath.cs
- TableLayoutPanelCellPosition.cs
- SimpleWorkerRequest.cs
- StringUtil.cs
- IgnoreDeviceFilterElementCollection.cs
- InstanceCreationEditor.cs
- ColorDialog.cs