Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / ExtenderProvidedPropertyAttribute.cs / 1 / ExtenderProvidedPropertyAttribute.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 ExtenderProvidedPropertyAttribute : Attribute { private PropertyDescriptor extenderProperty; private IExtenderProvider provider; private Type receiverType; ////// ExtenderProvidedPropertyAttribute is an attribute that marks that a property /// was actually offered up by and extender provider. /// ////// Creates a new ExtenderProvidedPropertyAttribute. /// internal static ExtenderProvidedPropertyAttribute Create(PropertyDescriptor extenderProperty, Type receiverType, IExtenderProvider provider) { ExtenderProvidedPropertyAttribute e = new ExtenderProvidedPropertyAttribute(); e.extenderProperty = extenderProperty; e.receiverType = receiverType; e.provider = provider; return e; } ////// Creates an empty ExtenderProvidedPropertyAttribute. /// public ExtenderProvidedPropertyAttribute() { } ////// PropertyDescriptor of the property that is being provided. /// public PropertyDescriptor ExtenderProperty { get { return extenderProperty; } } ////// Extender provider that is providing the property. /// public IExtenderProvider Provider { get { return provider; } } ////// The type of object that can receive these properties. /// public Type ReceiverType { get { return receiverType; } } public override bool Equals(object obj) { if (obj == this) { return true; } ExtenderProvidedPropertyAttribute other = obj as ExtenderProvidedPropertyAttribute; return (other != null) && other.extenderProperty.Equals(extenderProperty) && other.provider.Equals(provider) && other.receiverType.Equals(receiverType); } public override int GetHashCode() { return base.GetHashCode(); } ////// /// public override bool IsDefaultAttribute() { return receiverType == null; } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- MouseButton.cs
- QueryableFilterUserControl.cs
- ToolStripPanelSelectionBehavior.cs
- EventLogger.cs
- ParentUndoUnit.cs
- CommandArguments.cs
- LinkClickEvent.cs
- Choices.cs
- _TLSstream.cs
- HttpWriter.cs
- GestureRecognizer.cs
- DataContractSet.cs
- GeneralTransformCollection.cs
- SmiEventSink_Default.cs
- SingleConverter.cs
- ECDiffieHellman.cs
- ContainerVisual.cs
- AsymmetricKeyExchangeFormatter.cs
- BulletedListEventArgs.cs
- AnnotationService.cs
- AttributeCollection.cs
- CodeSnippetExpression.cs
- WebColorConverter.cs
- ToolStripPanelDesigner.cs
- SimpleApplicationHost.cs
- UntrustedRecipientException.cs
- ProcessProtocolHandler.cs
- Visual.cs
- SpecularMaterial.cs
- TagPrefixAttribute.cs
- VSWCFServiceContractGenerator.cs
- DuplicateMessageDetector.cs
- StrongNameUtility.cs
- RoleProviderPrincipal.cs
- OracleTransaction.cs
- GraphicsPathIterator.cs
- NameValuePermission.cs
- WebFormsRootDesigner.cs
- DesignerForm.cs
- PreloadedPackages.cs
- KoreanCalendar.cs
- ThreadStaticAttribute.cs
- ObjectManager.cs
- MemoryFailPoint.cs
- DesignerActionVerbList.cs
- AudioLevelUpdatedEventArgs.cs
- Function.cs
- documentsequencetextcontainer.cs
- UnsafeNativeMethods.cs
- DataGridViewRowStateChangedEventArgs.cs
- ThicknessAnimationBase.cs
- Part.cs
- LicenseContext.cs
- XpsResourceDictionary.cs
- App.cs
- ExpressionVisitor.cs
- HtmlInputControl.cs
- Identifier.cs
- FocusWithinProperty.cs
- TextTrailingWordEllipsis.cs
- NavigationPropertyEmitter.cs
- X509CertificateCollection.cs
- SqlTransaction.cs
- BindingContext.cs
- DataMember.cs
- DataTableCollection.cs
- Viewport3DVisual.cs
- StorageEntityContainerMapping.cs
- WebControlAdapter.cs
- AuthorizationSection.cs
- RTLAwareMessageBox.cs
- TitleStyle.cs
- LiteralLink.cs
- CacheForPrimitiveTypes.cs
- HttpDebugHandler.cs
- WebPermission.cs
- LinqMaximalSubtreeNominator.cs
- ResolveCriteria11.cs
- XmlDictionaryReader.cs
- MobileListItemCollection.cs
- TagElement.cs
- ComAdminInterfaces.cs
- XmlCustomFormatter.cs
- SecurityContext.cs
- XmlSchemaComplexContent.cs
- Point.cs
- TextAction.cs
- ManagedIStream.cs
- SendMailErrorEventArgs.cs
- StorageMappingItemCollection.cs
- Helpers.cs
- NonBatchDirectoryCompiler.cs
- NonVisualControlAttribute.cs
- Msec.cs
- Rectangle.cs
- NullableLongMinMaxAggregationOperator.cs
- XmlDataCollection.cs
- BridgeDataRecord.cs
- TypedServiceChannelBuilder.cs
- DeclarativeCatalogPart.cs