Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / ExtenderProvidedPropertyAttribute.cs / 1305376 / 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; } } } // 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; ////// /// [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; } } } // 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
- BaseAddressElementCollection.cs
- BinaryConverter.cs
- MDIWindowDialog.cs
- HtmlForm.cs
- ObjectListGeneralPage.cs
- XmlCharCheckingReader.cs
- SplitterEvent.cs
- ForceCopyBuildProvider.cs
- MemberBinding.cs
- DataGridLinkButton.cs
- TrackingServices.cs
- PerfService.cs
- HTMLTagNameToTypeMapper.cs
- LinqDataSource.cs
- TextTreeExtractElementUndoUnit.cs
- IPEndPointCollection.cs
- ColorConvertedBitmapExtension.cs
- HashHelper.cs
- GeometryHitTestParameters.cs
- CroppedBitmap.cs
- CodeValidator.cs
- TrustManagerPromptUI.cs
- CodeStatementCollection.cs
- DataSourceCacheDurationConverter.cs
- WeakRefEnumerator.cs
- OutputCacheSettings.cs
- HtmlUtf8RawTextWriter.cs
- TextTrailingWordEllipsis.cs
- PointCollectionConverter.cs
- XmlSerializationWriter.cs
- X509ChainPolicy.cs
- SyndicationCategory.cs
- DependencyObjectType.cs
- MenuItemStyle.cs
- DigestComparer.cs
- CodeLabeledStatement.cs
- XsltSettings.cs
- MeshGeometry3D.cs
- HostSecurityManager.cs
- LookupNode.cs
- CharUnicodeInfo.cs
- EntityDataSourceWrapperPropertyDescriptor.cs
- BatchServiceHost.cs
- DefaultShape.cs
- CssStyleCollection.cs
- ConsoleCancelEventArgs.cs
- WorkflowTransactionService.cs
- MarkerProperties.cs
- DriveNotFoundException.cs
- ELinqQueryState.cs
- ScriptingRoleServiceSection.cs
- DllNotFoundException.cs
- Accessible.cs
- COM2Enum.cs
- XmlAnyElementAttributes.cs
- DataListDesigner.cs
- FtpRequestCacheValidator.cs
- querybuilder.cs
- Catch.cs
- GroupItemAutomationPeer.cs
- CustomTypeDescriptor.cs
- UpDownBase.cs
- securitycriticaldataClass.cs
- Pkcs9Attribute.cs
- ListControl.cs
- InternalsVisibleToAttribute.cs
- BitmapMetadataBlob.cs
- Ipv6Element.cs
- ConfigurationManagerInternalFactory.cs
- XmlChildNodes.cs
- AssemblyUtil.cs
- TokenDescriptor.cs
- Freezable.cs
- ClearTypeHintValidation.cs
- __TransparentProxy.cs
- Int64AnimationUsingKeyFrames.cs
- SqlCharStream.cs
- EntryPointNotFoundException.cs
- DrawingDrawingContext.cs
- KeysConverter.cs
- JoinSymbol.cs
- AuthorizationRuleCollection.cs
- VisualStyleTypesAndProperties.cs
- MemberInfoSerializationHolder.cs
- HeaderedItemsControl.cs
- BitmapMetadataEnumerator.cs
- ParentUndoUnit.cs
- PermissionListSet.cs
- WebPartVerb.cs
- AncillaryOps.cs
- CharAnimationUsingKeyFrames.cs
- ListViewInsertionMark.cs
- ProxyWebPart.cs
- DataGridViewRowConverter.cs
- InputLanguageCollection.cs
- WpfKnownType.cs
- StringKeyFrameCollection.cs
- XMLSyntaxException.cs
- WMICapabilities.cs
- CodeTryCatchFinallyStatement.cs