Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / CompMod / System / ComponentModel / BrowsableAttribute.cs / 1 / BrowsableAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.ComponentModel; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class BrowsableAttribute : Attribute { ///Specifies whether a property or event should be displayed in /// a property browsing window. ////// public static readonly BrowsableAttribute Yes = new BrowsableAttribute(true); ////// Specifies that a property or event can be modified at /// design time. This ////// field is read-only. /// /// public static readonly BrowsableAttribute No = new BrowsableAttribute(false); ////// Specifies that a property or event cannot be modified at /// design time. This ///field is read-only. /// /// public static readonly BrowsableAttribute Default = Yes; private bool browsable = true; ///Specifies the default value for the ///, /// which is . This field is read-only. /// public BrowsableAttribute(bool browsable) { this.browsable = browsable; } ///Initializes a new instance of the ///class. /// public bool Browsable { get { return browsable; } } ////// Gets a value indicating whether an object is browsable. /// ////// /// public override bool Equals(object obj) { if (obj == this) { return true; } BrowsableAttribute other = obj as BrowsableAttribute; return (other != null) && other.Browsable == browsable; } ////// public override int GetHashCode() { return browsable.GetHashCode(); } ///[To be supplied.] ////// /// public override bool IsDefaultAttribute() { return (this.Equals(Default)); } } } // 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.ComponentModel; using System.Diagnostics; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class BrowsableAttribute : Attribute { ///Specifies whether a property or event should be displayed in /// a property browsing window. ////// public static readonly BrowsableAttribute Yes = new BrowsableAttribute(true); ////// Specifies that a property or event can be modified at /// design time. This ////// field is read-only. /// /// public static readonly BrowsableAttribute No = new BrowsableAttribute(false); ////// Specifies that a property or event cannot be modified at /// design time. This ///field is read-only. /// /// public static readonly BrowsableAttribute Default = Yes; private bool browsable = true; ///Specifies the default value for the ///, /// which is . This field is read-only. /// public BrowsableAttribute(bool browsable) { this.browsable = browsable; } ///Initializes a new instance of the ///class. /// public bool Browsable { get { return browsable; } } ////// Gets a value indicating whether an object is browsable. /// ////// /// public override bool Equals(object obj) { if (obj == this) { return true; } BrowsableAttribute other = obj as BrowsableAttribute; return (other != null) && other.Browsable == browsable; } ////// public override int GetHashCode() { return browsable.GetHashCode(); } ///[To be supplied.] ////// /// public override bool IsDefaultAttribute() { return (this.Equals(Default)); } } } // 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
- Timer.cs
- SqlCacheDependencyDatabaseCollection.cs
- Stack.cs
- EqualityComparer.cs
- ValidatorCollection.cs
- SingleSelectRootGridEntry.cs
- LocationInfo.cs
- GeneralTransform2DTo3D.cs
- XPathDocument.cs
- DefinitionBase.cs
- EntityStoreSchemaGenerator.cs
- BaseEntityWrapper.cs
- _UriTypeConverter.cs
- EnumerableCollectionView.cs
- PartialArray.cs
- CompilerTypeWithParams.cs
- ISCIIEncoding.cs
- BinaryFormatter.cs
- XamlPointCollectionSerializer.cs
- CustomValidator.cs
- NotImplementedException.cs
- ListBoxItemWrapperAutomationPeer.cs
- HtmlFormParameterReader.cs
- TransformPatternIdentifiers.cs
- SqlUtil.cs
- LocalBuilder.cs
- WebPartConnectionsCancelEventArgs.cs
- ServiceEndpointElementCollection.cs
- ObfuscateAssemblyAttribute.cs
- documentsequencetextpointer.cs
- SingleObjectCollection.cs
- RegexCharClass.cs
- ClientTargetSection.cs
- Path.cs
- DataObjectEventArgs.cs
- DataViewSetting.cs
- RolePrincipal.cs
- ReflectTypeDescriptionProvider.cs
- SharedPerformanceCounter.cs
- PropertyEntry.cs
- MasterPage.cs
- XmlSchemaSimpleTypeRestriction.cs
- AsyncResult.cs
- AccessDataSource.cs
- RectangleF.cs
- _PooledStream.cs
- InputBindingCollection.cs
- Marshal.cs
- XomlCompilerResults.cs
- MimeTypePropertyAttribute.cs
- EventLog.cs
- AuthenticationManager.cs
- AuthenticatingEventArgs.cs
- CqlLexerHelpers.cs
- ToolboxItemCollection.cs
- BuilderPropertyEntry.cs
- HierarchicalDataBoundControl.cs
- TreeViewHitTestInfo.cs
- HandleCollector.cs
- AssemblyCache.cs
- EventPrivateKey.cs
- ComboBoxItem.cs
- Message.cs
- ActiveXHelper.cs
- PipelineModuleStepContainer.cs
- ItemsPanelTemplate.cs
- StructuralCache.cs
- JsonMessageEncoderFactory.cs
- DetailsViewInsertedEventArgs.cs
- AutoResetEvent.cs
- TransactionTable.cs
- HashAlgorithm.cs
- WorkflowDefinitionDispenser.cs
- DurableRuntimeValidator.cs
- CollectionView.cs
- PreservationFileReader.cs
- PathGeometry.cs
- _SSPIWrapper.cs
- DirectoryObjectSecurity.cs
- TableProviderWrapper.cs
- EndPoint.cs
- ObjectAssociationEndMapping.cs
- DataGridViewLinkColumn.cs
- WebRequestModuleElementCollection.cs
- UnsignedPublishLicense.cs
- ItemsPresenter.cs
- CompensationTokenData.cs
- WebPartZoneBase.cs
- SafeHandle.cs
- CompositeControl.cs
- CoreSwitches.cs
- DataGridViewSelectedCellsAccessibleObject.cs
- ImageBrush.cs
- CodeLinePragma.cs
- AnimatedTypeHelpers.cs
- DataGridTextBox.cs
- ImmutableCollection.cs
- DependencyPropertyValueSerializer.cs
- SiteMapNodeItem.cs
- CurrencyWrapper.cs