Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / 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
- WindowsRebar.cs
- AsymmetricAlgorithm.cs
- Int16Animation.cs
- IntMinMaxAggregationOperator.cs
- XmlToDatasetMap.cs
- InternalsVisibleToAttribute.cs
- EntityClientCacheKey.cs
- NotSupportedException.cs
- DateTimeValueSerializerContext.cs
- XsdDateTime.cs
- PersonalizableTypeEntry.cs
- ExpressionDumper.cs
- WebChannelFactory.cs
- AssociationTypeEmitter.cs
- XmlNamespaceDeclarationsAttribute.cs
- UpdatePanelTrigger.cs
- BigInt.cs
- ScrollProperties.cs
- CachedTypeface.cs
- LifetimeServices.cs
- ContractNamespaceAttribute.cs
- ValueType.cs
- ScriptBehaviorDescriptor.cs
- SamlAuthorizationDecisionClaimResource.cs
- SafeLibraryHandle.cs
- StorageComplexTypeMapping.cs
- SplitterDesigner.cs
- ScriptingWebServicesSectionGroup.cs
- VariableValue.cs
- Menu.cs
- FontStretches.cs
- AuthenticationServiceManager.cs
- TextSelectionHighlightLayer.cs
- ValidatorCompatibilityHelper.cs
- ExecutionScope.cs
- EditingCommands.cs
- TextTreeTextNode.cs
- DataPagerFieldCommandEventArgs.cs
- StylusSystemGestureEventArgs.cs
- HttpWriter.cs
- MdiWindowListItemConverter.cs
- Comparer.cs
- Span.cs
- Util.cs
- NaturalLanguageHyphenator.cs
- OperandQuery.cs
- XsltArgumentList.cs
- ConfigUtil.cs
- AxHost.cs
- CopyNodeSetAction.cs
- ObjectCloneHelper.cs
- LinearKeyFrames.cs
- WorkerRequest.cs
- NestedContainer.cs
- HwndAppCommandInputProvider.cs
- ReflectionPermission.cs
- SequenceNumber.cs
- ISAPIWorkerRequest.cs
- Fx.cs
- ProxySimple.cs
- OdbcCommand.cs
- HostingPreferredMapPath.cs
- TextParentUndoUnit.cs
- XXXOnTypeBuilderInstantiation.cs
- TableLayoutPanelBehavior.cs
- Hashtable.cs
- StatusBar.cs
- ThumbButtonInfo.cs
- RichTextBoxConstants.cs
- ProfileServiceManager.cs
- DelegatingHeader.cs
- Int32CollectionConverter.cs
- _AutoWebProxyScriptEngine.cs
- RecognitionEventArgs.cs
- WeakReferenceKey.cs
- XmlSchemaObject.cs
- ComponentGuaranteesAttribute.cs
- CompositeActivityTypeDescriptor.cs
- AppModelKnownContentFactory.cs
- TdsParserSafeHandles.cs
- XDeferredAxisSource.cs
- SearchForVirtualItemEventArgs.cs
- AttributeInfo.cs
- HtmlShimManager.cs
- AuthorizationRuleCollection.cs
- StatusBarPanelClickEvent.cs
- LabelEditEvent.cs
- DefaultParameterValueAttribute.cs
- SerialPinChanges.cs
- Keywords.cs
- RequestStatusBarUpdateEventArgs.cs
- EntityClientCacheKey.cs
- WsdlInspector.cs
- XmlUrlEditor.cs
- FixedElement.cs
- WsdlBuildProvider.cs
- CommonXSendMessage.cs
- TypeDescriptionProviderAttribute.cs
- RadioButton.cs
- XmlSerializerVersionAttribute.cs