Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Base / System / Windows / Markup / ContentWrapperAttribute.cs / 1 / ContentWrapperAttribute.cs
//---------------------------------------------------------------------------- // // Microsoft Windows Client Platform // Copyright (C) Microsoft Corporation, 2005 // // File: ContentWrapperAttribute.cs // // Description: Can be specified on a collection type to indicate which // types are used to wrap content foreign content such as // strings in a strongly type Collection. // // Created: 06/07/2005 chuckj // //--------------------------------------------------------------------------- namespace System.Windows.Markup { using System; /// /// Can be specified on a collection type to indicate which /// types are used to wrap content foreign content such as /// strings in a strongly type Collection. /// [AttributeUsage(AttributeTargets.Class, AllowMultiple = true, Inherited = true)] sealed public class ContentWrapperAttribute : Attribute { ////// Declares the given type as being a content wrapper for the collection /// type this attribute is declared on. /// /// public ContentWrapperAttribute(Type contentWrapper) { _contentWrapper = contentWrapper; } ////// The type that is declared as a content wrapper for the collection type /// this attribute is declared on. /// public Type ContentWrapper { get { return _contentWrapper; } } ////// Override to ensure AttributeCollection perserves all instances /// public override object TypeId { get { return this; } } ////// Overrides Object.Equals to implement correct equality semantics for this /// attribute. /// public override bool Equals(object obj) { ContentWrapperAttribute other = obj as ContentWrapperAttribute; if (other == null) return false; return _contentWrapper == other._contentWrapper; } ////// Overrides Object.GetHashCode to implement correct hashing semantics. /// public override int GetHashCode() { return _contentWrapper.GetHashCode(); } private Type _contentWrapper; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TreeNodeSelectionProcessor.cs
- PrivateUnsafeNativeCompoundFileMethods.cs
- WebServiceErrorEvent.cs
- AnnotationAdorner.cs
- XamlTreeBuilder.cs
- RotateTransform3D.cs
- Util.cs
- SwitchAttribute.cs
- WhitespaceRule.cs
- SqlExpressionNullability.cs
- AppSettings.cs
- PlanCompilerUtil.cs
- DataBoundControlHelper.cs
- DataGridViewRowPrePaintEventArgs.cs
- LinkLabel.cs
- HtmlTextBoxAdapter.cs
- Journal.cs
- DbDataAdapter.cs
- DocumentReferenceCollection.cs
- OutOfMemoryException.cs
- StyleModeStack.cs
- ListenerElementsCollection.cs
- HttpDateParse.cs
- SafeSystemMetrics.cs
- SafeRegistryHandle.cs
- MarkupProperty.cs
- brushes.cs
- XmlSchemaAppInfo.cs
- PropertyOrder.cs
- SqlSupersetValidator.cs
- Graphics.cs
- CodeRemoveEventStatement.cs
- ControlEvent.cs
- XPathNodePointer.cs
- BCryptHashAlgorithm.cs
- SqlConnection.cs
- InputLanguageEventArgs.cs
- DelegateSerializationHolder.cs
- InputManager.cs
- JavaScriptString.cs
- MaterialGroup.cs
- ValidationVisibilityAttribute.cs
- DigitalSignatureProvider.cs
- COM2PropertyBuilderUITypeEditor.cs
- ValidationPropertyAttribute.cs
- ComponentChangedEvent.cs
- JournalEntryStack.cs
- CorrelationHandle.cs
- ParameterRetriever.cs
- IfAction.cs
- RightNameExpirationInfoPair.cs
- NullRuntimeConfig.cs
- TreeNodeBinding.cs
- UpdateCommandGenerator.cs
- TextDecorationCollection.cs
- TdsParameterSetter.cs
- LongValidator.cs
- CatalogPartChrome.cs
- DrawListViewColumnHeaderEventArgs.cs
- RelatedEnd.cs
- FileDialogCustomPlace.cs
- GroupBox.cs
- DataGridHelper.cs
- DefaultDiscoveryServiceExtension.cs
- DictionaryEditChange.cs
- EnumBuilder.cs
- TransformPatternIdentifiers.cs
- Stream.cs
- LogLogRecordEnumerator.cs
- SecurityUtils.cs
- MethodRental.cs
- FormViewModeEventArgs.cs
- TreeNodeStyleCollectionEditor.cs
- CookieHandler.cs
- CacheForPrimitiveTypes.cs
- IISMapPath.cs
- SSmlParser.cs
- AppDomainManager.cs
- TrackBarRenderer.cs
- ConstructorArgumentAttribute.cs
- GridItemProviderWrapper.cs
- MailHeaderInfo.cs
- StylusTip.cs
- NumericExpr.cs
- CalloutQueueItem.cs
- AesManaged.cs
- BinaryReader.cs
- DeploymentExceptionMapper.cs
- PowerModeChangedEventArgs.cs
- Grid.cs
- TrustLevelCollection.cs
- EventDescriptorCollection.cs
- TextFormatterContext.cs
- ListView.cs
- RuntimeVariablesExpression.cs
- ImageSourceConverter.cs
- HttpConfigurationContext.cs
- PhoneCallDesigner.cs
- CannotUnloadAppDomainException.cs
- CacheSection.cs