Code:
/ 4.0 / 4.0 / untmp / 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;
///
/// Specifies whether a property should be localized.
///
[AttributeUsage(AttributeTargets.All)]
public sealed class LocalizableAttribute : Attribute {
private bool isLocalizable = false;
///
///
/// Initializes a new instance of the class.
///
///
public LocalizableAttribute(bool isLocalizable) {
this.isLocalizable = isLocalizable;
}
///
///
/// Gets a value indicating whether
/// a property should be localized.
///
///
public bool IsLocalizable {
get {
return isLocalizable;
}
}
///
///
/// Specifies that a property should be localized. This
/// field is read-only.
///
///
public static readonly LocalizableAttribute Yes = new LocalizableAttribute(true);
///
///
/// Specifies that a property should not be localized. This
/// field is read-only.
///
///
public static readonly LocalizableAttribute No = new LocalizableAttribute(false);
///
///
/// Specifies the default value, which is , that is
/// a property should not be localized. This field is
/// read-only.
///
///
public static readonly LocalizableAttribute Default = No;
///
///
///
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
- TableItemStyle.cs
- EventLogHandle.cs
- OptimalBreakSession.cs
- Emitter.cs
- Msec.cs
- DataGridViewRowCollection.cs
- MexHttpsBindingElement.cs
- PropertyTab.cs
- Comparer.cs
- pingexception.cs
- FocusTracker.cs
- MsmqIntegrationBindingElement.cs
- GeneratedView.cs
- EntityDataSourceColumn.cs
- ExecutionContext.cs
- SamlAuthenticationClaimResource.cs
- DetailsViewCommandEventArgs.cs
- DeclaredTypeValidatorAttribute.cs
- PackUriHelper.cs
- Stream.cs
- AsymmetricSignatureDeformatter.cs
- RegionIterator.cs
- XmlSchemaComplexType.cs
- configsystem.cs
- EventLogPermissionEntry.cs
- _ConnectOverlappedAsyncResult.cs
- SeekableReadStream.cs
- PartialList.cs
- SchemaTypeEmitter.cs
- PolyQuadraticBezierSegment.cs
- EntityProviderServices.cs
- DecoderFallback.cs
- ObjectDataSourceEventArgs.cs
- TreeNode.cs
- _ServiceNameStore.cs
- LOSFormatter.cs
- URLAttribute.cs
- ContainerControl.cs
- SqlDataSourceView.cs
- XmlConverter.cs
- PageParser.cs
- SchemaImporterExtensionElement.cs
- ObjectPersistData.cs
- BitmapData.cs
- MarkupExtensionParser.cs
- ComponentEvent.cs
- SerializationStore.cs
- ConfigXmlWhitespace.cs
- isolationinterop.cs
- WebPartZoneBase.cs
- NonSerializedAttribute.cs
- CultureInfoConverter.cs
- ComAdminInterfaces.cs
- ContentOperations.cs
- ConfigurationCollectionAttribute.cs
- Line.cs
- StrongTypingException.cs
- SqlLiftIndependentRowExpressions.cs
- ParameterToken.cs
- CustomPopupPlacement.cs
- ClientProtocol.cs
- AvTraceFormat.cs
- Missing.cs
- EntityAdapter.cs
- BufferModesCollection.cs
- BlurBitmapEffect.cs
- RemoveStoryboard.cs
- ParserContext.cs
- TextComposition.cs
- WebBaseEventKeyComparer.cs
- XmlCharType.cs
- ResponseStream.cs
- LabelInfo.cs
- BaseAsyncResult.cs
- ValidatingReaderNodeData.cs
- WebPartExportVerb.cs
- XmlSchemaFacet.cs
- CacheOutputQuery.cs
- MD5CryptoServiceProvider.cs
- selecteditemcollection.cs
- UriExt.cs
- ImplicitInputBrush.cs
- BStrWrapper.cs
- MetadataSerializer.cs
- OletxDependentTransaction.cs
- ButtonChrome.cs
- StylusPlugInCollection.cs
- TimelineGroup.cs
- SqlPersonalizationProvider.cs
- SubpageParagraph.cs
- NativeCompoundFileAPIs.cs
- DataException.cs
- JoinElimination.cs
- WindowsRichEditRange.cs
- Selection.cs
- PrimitiveDataContract.cs
- XpsFilter.cs
- FacetDescription.cs
- XsdCachingReader.cs
- StreamGeometry.cs