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 / Design / ParenthesizePropertyNameAttribute.cs / 1 / ParenthesizePropertyNameAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using System; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class ParenthesizePropertyNameAttribute : Attribute { ///Provides a value indicating whether the name of the associated property is parenthesized in the /// properties window. ////// public static readonly ParenthesizePropertyNameAttribute Default = new ParenthesizePropertyNameAttribute(); private bool needParenthesis; ////// Sets the System.ComponentModel.Design.ParenthesizePropertyName /// attribute by default to /// ///. /// /// public ParenthesizePropertyNameAttribute() : this(false) { } ///[To be supplied.] ////// public ParenthesizePropertyNameAttribute(bool needParenthesis) { this.needParenthesis = needParenthesis; } ///Initializes a new instance of the System.ComponentModel.Design.ParenthesizePropertyNameAttribute /// class, using the specified value to indicate whether the attribute is /// marked for display with parentheses. ////// public bool NeedParenthesis { get { return needParenthesis; } } ////// Gets a value indicating /// whether the /// attribute is placed in parentheses when listed in /// the properties window. /// ////// public override bool Equals(object o) { if (o is ParenthesizePropertyNameAttribute) { return ((ParenthesizePropertyNameAttribute)o).NeedParenthesis == needParenthesis; } return false; } ///Compares the specified object /// to this object and tests for equality. ////// public override int GetHashCode() { return base.GetHashCode(); } ////// Returns the hashcode for this object. /// ////// public override bool IsDefaultAttribute() { return this.Equals(Default); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //Gets a value indicating whether this attribute is set to ///by default. // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using System; using System.Security.Permissions; ////// [AttributeUsage(AttributeTargets.All)] public sealed class ParenthesizePropertyNameAttribute : Attribute { ///Provides a value indicating whether the name of the associated property is parenthesized in the /// properties window. ////// public static readonly ParenthesizePropertyNameAttribute Default = new ParenthesizePropertyNameAttribute(); private bool needParenthesis; ////// Sets the System.ComponentModel.Design.ParenthesizePropertyName /// attribute by default to /// ///. /// /// public ParenthesizePropertyNameAttribute() : this(false) { } ///[To be supplied.] ////// public ParenthesizePropertyNameAttribute(bool needParenthesis) { this.needParenthesis = needParenthesis; } ///Initializes a new instance of the System.ComponentModel.Design.ParenthesizePropertyNameAttribute /// class, using the specified value to indicate whether the attribute is /// marked for display with parentheses. ////// public bool NeedParenthesis { get { return needParenthesis; } } ////// Gets a value indicating /// whether the /// attribute is placed in parentheses when listed in /// the properties window. /// ////// public override bool Equals(object o) { if (o is ParenthesizePropertyNameAttribute) { return ((ParenthesizePropertyNameAttribute)o).NeedParenthesis == needParenthesis; } return false; } ///Compares the specified object /// to this object and tests for equality. ////// public override int GetHashCode() { return base.GetHashCode(); } ////// Returns the hashcode for this object. /// ////// public override bool IsDefaultAttribute() { return this.Equals(Default); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Gets a value indicating whether this attribute is set to ///by default.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- FileReservationCollection.cs
- DbCommandTree.cs
- SiteMapDataSource.cs
- XPathNavigatorException.cs
- XmlSchemaComplexContentExtension.cs
- ConfigViewGenerator.cs
- DeclarativeCatalogPart.cs
- Point.cs
- ListBoxAutomationPeer.cs
- PtsPage.cs
- InteropDesigner.xaml.cs
- DbConnectionFactory.cs
- Ops.cs
- AdornerLayer.cs
- CatalogPartChrome.cs
- CloudCollection.cs
- ConfigurationPermission.cs
- SqlProviderServices.cs
- KeyProperty.cs
- NonBatchDirectoryCompiler.cs
- FilterQuery.cs
- URLString.cs
- UrlRoutingModule.cs
- BitmapEffectDrawingContent.cs
- FlowDocumentFormatter.cs
- AssemblyInfo.cs
- DifferencingCollection.cs
- ConfigXmlComment.cs
- UnsafeNativeMethods.cs
- ConfigurationFileMap.cs
- TreeView.cs
- NativeCompoundFileAPIs.cs
- panel.cs
- BasicExpandProvider.cs
- ProtocolsSection.cs
- _LocalDataStoreMgr.cs
- EdmToObjectNamespaceMap.cs
- WebControlsSection.cs
- QilList.cs
- KnownBoxes.cs
- LabelInfo.cs
- ButtonRenderer.cs
- PrivilegedConfigurationManager.cs
- Decoder.cs
- InteropBitmapSource.cs
- MenuCommand.cs
- Process.cs
- PlacementWorkspace.cs
- SHA384Cng.cs
- PageSetupDialog.cs
- PeerCollaborationPermission.cs
- SecurityVerifiedMessage.cs
- WorkflowServiceHost.cs
- SmiSettersStream.cs
- DynamicPropertyHolder.cs
- StringAnimationUsingKeyFrames.cs
- VisualBrush.cs
- TraceData.cs
- AuthenticationManager.cs
- SpinLock.cs
- TargetControlTypeAttribute.cs
- RuntimeHandles.cs
- LocalizedNameDescriptionPair.cs
- Propagator.Evaluator.cs
- hresults.cs
- String.cs
- CallbackException.cs
- ResourceProperty.cs
- AsyncOperationManager.cs
- XmlSerializerNamespaces.cs
- Properties.cs
- TableRow.cs
- HttpServerVarsCollection.cs
- PartialTrustVisibleAssemblyCollection.cs
- QueryAsyncResult.cs
- MethodCallExpression.cs
- SystemNetworkInterface.cs
- KeyTimeConverter.cs
- DataGridRowClipboardEventArgs.cs
- TableCellCollection.cs
- DataService.cs
- ObjectDataSourceDisposingEventArgs.cs
- AuthenticateEventArgs.cs
- GeneralTransform.cs
- ResourceReader.cs
- CodeCommentStatementCollection.cs
- ReversePositionQuery.cs
- HttpHandlersSection.cs
- CodeGenerator.cs
- XmlNamespaceMappingCollection.cs
- MobileTextWriter.cs
- InternalDispatchObject.cs
- FunctionImportElement.cs
- FloaterBaseParaClient.cs
- StrongNameHelpers.cs
- RIPEMD160Managed.cs
- WpfMemberInvoker.cs
- MessageSmuggler.cs
- ImageListImageEditor.cs
- SharedPerformanceCounter.cs