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
- UriExt.cs
- EdmSchemaError.cs
- LocationSectionRecord.cs
- OleDbPermission.cs
- LinqDataSource.cs
- PhysicalFontFamily.cs
- XmlSerializableServices.cs
- ObjRef.cs
- HeaderedContentControl.cs
- StronglyTypedResourceBuilder.cs
- GroupStyle.cs
- DbConnectionPoolIdentity.cs
- CustomBindingElementCollection.cs
- SafeRightsManagementQueryHandle.cs
- DocumentSequenceHighlightLayer.cs
- DSACryptoServiceProvider.cs
- ApplicationInterop.cs
- TextEndOfLine.cs
- SelectionProcessor.cs
- ManagementInstaller.cs
- FormsAuthenticationCredentials.cs
- IsolatedStoragePermission.cs
- SoapIncludeAttribute.cs
- BufferModesCollection.cs
- Material.cs
- DataGridViewCellValueEventArgs.cs
- SoapExtensionTypeElement.cs
- JoinCqlBlock.cs
- AssertFilter.cs
- BlockUIContainer.cs
- DataGridViewCheckBoxColumn.cs
- WebPartCollection.cs
- ExpandButtonVisibilityConverter.cs
- DependencyObjectProvider.cs
- OracleSqlParser.cs
- EntityTypeBase.cs
- CompositeActivityCodeGenerator.cs
- AdornerPresentationContext.cs
- ExceptionValidationRule.cs
- NameTable.cs
- AQNBuilder.cs
- MultitargetUtil.cs
- StructuralObject.cs
- ModifierKeysValueSerializer.cs
- OleDbWrapper.cs
- ButtonBaseAdapter.cs
- SQLInt64.cs
- ShaderEffect.cs
- IPAddress.cs
- AssertSection.cs
- CompModSwitches.cs
- SID.cs
- WorkflowInstanceAbortedRecord.cs
- XmlException.cs
- ControlPaint.cs
- StructuralCache.cs
- SocketElement.cs
- TrackingMemoryStreamFactory.cs
- DataGridViewSelectedRowCollection.cs
- ResXResourceReader.cs
- ColorAnimation.cs
- EventSourceCreationData.cs
- RunInstallerAttribute.cs
- __Error.cs
- HtmlEmptyTagControlBuilder.cs
- ToolTipService.cs
- FixedFlowMap.cs
- XmlTypeAttribute.cs
- WindowsProgressbar.cs
- ObjectView.cs
- loginstatus.cs
- NetTcpBindingElement.cs
- WindowsSpinner.cs
- CreateUserWizard.cs
- CachedTypeface.cs
- ArgumentException.cs
- FileDialogCustomPlacesCollection.cs
- ipaddressinformationcollection.cs
- SecurityAlgorithmSuite.cs
- WindowsRichEditRange.cs
- FormViewUpdateEventArgs.cs
- CriticalHandle.cs
- SmiTypedGetterSetter.cs
- TypeReference.cs
- ScriptServiceAttribute.cs
- AutomationAttributeInfo.cs
- SplitterDesigner.cs
- FormatException.cs
- XmlSchemaGroup.cs
- VideoDrawing.cs
- XmlSchemaSimpleContentExtension.cs
- oledbconnectionstring.cs
- _LocalDataStore.cs
- COM2IDispatchConverter.cs
- BamlLocalizerErrorNotifyEventArgs.cs
- Panel.cs
- TcpActivation.cs
- TextWriterTraceListener.cs
- DefaultSection.cs
- RuntimeHandles.cs