Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / CompMod / System / ComponentModel / SettingsBindableAttribute.cs / 1 / SettingsBindableAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// Use this attribute to specify typical properties on components that can be bound /// to application settings. /// [AttributeUsage(AttributeTargets.Property)] public sealed class SettingsBindableAttribute : Attribute { ////// Specifies that a property is appropriate to bind settings to. /// public static readonly SettingsBindableAttribute Yes = new SettingsBindableAttribute(true); ////// Specifies that a property is not appropriate to bind settings to. /// public static readonly SettingsBindableAttribute No = new SettingsBindableAttribute(false); private bool _bindable = false; public SettingsBindableAttribute(bool bindable) { _bindable = bindable; } ////// Gets a value indicating whether a property is appropriate to bind settings to. /// public bool Bindable { get { return _bindable; } } public override bool Equals(object obj) { if (obj == this) { return true; } if (obj != null && obj is SettingsBindableAttribute) { return (((SettingsBindableAttribute)obj).Bindable == _bindable); } return false; } public override int GetHashCode() { return _bindable.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; ////// Use this attribute to specify typical properties on components that can be bound /// to application settings. /// [AttributeUsage(AttributeTargets.Property)] public sealed class SettingsBindableAttribute : Attribute { ////// Specifies that a property is appropriate to bind settings to. /// public static readonly SettingsBindableAttribute Yes = new SettingsBindableAttribute(true); ////// Specifies that a property is not appropriate to bind settings to. /// public static readonly SettingsBindableAttribute No = new SettingsBindableAttribute(false); private bool _bindable = false; public SettingsBindableAttribute(bool bindable) { _bindable = bindable; } ////// Gets a value indicating whether a property is appropriate to bind settings to. /// public bool Bindable { get { return _bindable; } } public override bool Equals(object obj) { if (obj == this) { return true; } if (obj != null && obj is SettingsBindableAttribute) { return (((SettingsBindableAttribute)obj).Bindable == _bindable); } return false; } public override int GetHashCode() { return _bindable.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
- TextAction.cs
- FixedDSBuilder.cs
- RegexEditorDialog.cs
- MenuItem.cs
- SqlConnectionFactory.cs
- DictionaryBase.cs
- WebConfigurationManager.cs
- OutputCacheModule.cs
- SizeConverter.cs
- ReverseQueryOperator.cs
- RequestCacheEntry.cs
- DataListItemCollection.cs
- MulticastIPAddressInformationCollection.cs
- ParserStreamGeometryContext.cs
- ModelService.cs
- LineSegment.cs
- DiscreteKeyFrames.cs
- Vector3D.cs
- ScaleTransform3D.cs
- Byte.cs
- SystemBrushes.cs
- PropertyRecord.cs
- StringBuilder.cs
- SchemaMerger.cs
- PropertyFilterAttribute.cs
- SlipBehavior.cs
- DataSourceControlBuilder.cs
- TargetInvocationException.cs
- OleTxTransaction.cs
- MbpInfo.cs
- BuildProvider.cs
- IdentifierCreationService.cs
- ImageIndexEditor.cs
- ZoomPercentageConverter.cs
- BufferedWebEventProvider.cs
- ServiceEndpointAssociationProvider.cs
- OlePropertyStructs.cs
- RangeValuePatternIdentifiers.cs
- XhtmlBasicValidatorAdapter.cs
- SystemIPInterfaceStatistics.cs
- DependencyPropertyConverter.cs
- Boolean.cs
- NoneExcludedImageIndexConverter.cs
- Range.cs
- UnsafeNativeMethods.cs
- InheritedPropertyChangedEventArgs.cs
- SiteMapProvider.cs
- RootBuilder.cs
- ToolStripDropDownClosingEventArgs.cs
- PerformanceCounterManager.cs
- cookiecollection.cs
- WebSysDisplayNameAttribute.cs
- SchemaContext.cs
- XmlAttributeCollection.cs
- HtmlInputHidden.cs
- AsyncPostBackTrigger.cs
- MiniAssembly.cs
- WmiInstallComponent.cs
- MsmqSecureHashAlgorithm.cs
- SystemIcmpV4Statistics.cs
- XmlNodeList.cs
- TabControlCancelEvent.cs
- DataServiceHostFactory.cs
- XmlSchemaSimpleType.cs
- ObjectContext.cs
- CrossContextChannel.cs
- RuleEngine.cs
- RemoteDebugger.cs
- PolyLineSegment.cs
- FaultException.cs
- UniqueTransportManagerRegistration.cs
- TracePayload.cs
- InvalidEnumArgumentException.cs
- DefaultBindingPropertyAttribute.cs
- TokenFactoryBase.cs
- SqlDataReaderSmi.cs
- FixedSOMImage.cs
- Bold.cs
- XmlSchemaCollection.cs
- Ops.cs
- InheritanceRules.cs
- InvokeMethodActivity.cs
- SchemaImporterExtensionsSection.cs
- StsCommunicationException.cs
- NameValuePermission.cs
- TransformerTypeCollection.cs
- ListParagraph.cs
- TransformCollection.cs
- SiteMapNodeItem.cs
- MatrixConverter.cs
- CodeAccessPermission.cs
- OutputWindow.cs
- PrintDialog.cs
- FontUnitConverter.cs
- CustomWebEventKey.cs
- Unit.cs
- ContextMenuStrip.cs
- ValueExpressions.cs
- PassportAuthenticationEventArgs.cs
- ConfigurationStrings.cs