Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Framework / System / Windows / Markup / KnownTypesHelper.cs / 1 / KnownTypesHelper.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // //--------------------------------------------------------------------------- using System; using System.IO; using System.Collections.Generic; using System.Reflection; using System.Diagnostics; // These are the non-generated parts of the KnownTypes and TypeIndexer classes #if PBTCOMPILER namespace MS.Internal.Markup #else namespace System.Windows.Markup #endif { internal static partial class KnownTypes { // Keep Known WCP Types in a private array, accessed through an indexer private static TypeIndexer _typeIndexer = new TypeIndexer((int)KnownElements.MaxElement); internal static TypeIndexer Types { get { return _typeIndexer; } } #if PBTCOMPILER internal static void InitializeKnownTypes(Assembly asmFramework, Assembly asmCore, Assembly asmBase) { _typeIndexer.Initialize(asmFramework, asmCore, asmBase); } #endif } internal partial class TypeIndexer { public TypeIndexer(int size) { _typeTable =new Type[size]; } public System.Type this[int index] { get { Type t = _typeTable[index]; if (t == null) { t = InitializeOneType((KnownElements)index); } _typeTable[index] = t; return t; } } private Type[] _typeTable; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // //--------------------------------------------------------------------------- using System; using System.IO; using System.Collections.Generic; using System.Reflection; using System.Diagnostics; // These are the non-generated parts of the KnownTypes and TypeIndexer classes #if PBTCOMPILER namespace MS.Internal.Markup #else namespace System.Windows.Markup #endif { internal static partial class KnownTypes { // Keep Known WCP Types in a private array, accessed through an indexer private static TypeIndexer _typeIndexer = new TypeIndexer((int)KnownElements.MaxElement); internal static TypeIndexer Types { get { return _typeIndexer; } } #if PBTCOMPILER internal static void InitializeKnownTypes(Assembly asmFramework, Assembly asmCore, Assembly asmBase) { _typeIndexer.Initialize(asmFramework, asmCore, asmBase); } #endif } internal partial class TypeIndexer { public TypeIndexer(int size) { _typeTable =new Type[size]; } public System.Type this[int index] { get { Type t = _typeTable[index]; if (t == null) { t = InitializeOneType((KnownElements)index); } _typeTable[index] = t; return t; } } private Type[] _typeTable; } } // 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
- WrappedIUnknown.cs
- SecurityKeyUsage.cs
- PassportAuthentication.cs
- Convert.cs
- TimersDescriptionAttribute.cs
- ProfileSection.cs
- RegexCompilationInfo.cs
- Addressing.cs
- PageAsyncTaskManager.cs
- RectKeyFrameCollection.cs
- WinFormsComponentEditor.cs
- WMIGenerator.cs
- ResourceContainer.cs
- SqlPersonalizationProvider.cs
- DataGridViewIntLinkedList.cs
- RequestBringIntoViewEventArgs.cs
- PtsContext.cs
- FrameworkContextData.cs
- GAC.cs
- JsonFormatGeneratorStatics.cs
- IUnknownConstantAttribute.cs
- ClientBuildManager.cs
- LowerCaseStringConverter.cs
- TextBox.cs
- ExtensionFile.cs
- EnterpriseServicesHelper.cs
- SecurityTokenTypes.cs
- ContentWrapperAttribute.cs
- FacetEnabledSchemaElement.cs
- Link.cs
- Timer.cs
- Connector.cs
- EventProxy.cs
- ContainerParagraph.cs
- ScrollProviderWrapper.cs
- CopyNodeSetAction.cs
- NativeCppClassAttribute.cs
- NativeMethods.cs
- ThreadAttributes.cs
- TaskFormBase.cs
- Group.cs
- LinkClickEvent.cs
- DataServiceConfiguration.cs
- UrlMappingsModule.cs
- MetadataHelper.cs
- CommentEmitter.cs
- XmlSchemaProviderAttribute.cs
- RtfControls.cs
- UnsafeNativeMethods.cs
- EventHandlingScope.cs
- OdbcError.cs
- AesManaged.cs
- CodeObject.cs
- ColorEditor.cs
- MULTI_QI.cs
- RelatedImageListAttribute.cs
- Matrix3DConverter.cs
- WebPartVerbCollection.cs
- _AutoWebProxyScriptHelper.cs
- PixelShader.cs
- RequestQueryProcessor.cs
- SqlUserDefinedAggregateAttribute.cs
- HostingEnvironmentSection.cs
- ScopedKnownTypes.cs
- RenderOptions.cs
- TraceListeners.cs
- SchemaTableOptionalColumn.cs
- MultipartContentParser.cs
- DrawingBrush.cs
- BitmapFrame.cs
- NativeMethods.cs
- DataGridViewTextBoxCell.cs
- ClientBuildManagerCallback.cs
- MiniConstructorInfo.cs
- BitmapFrameEncode.cs
- DesignerAutoFormatCollection.cs
- CollectionDataContract.cs
- Contracts.cs
- ProfessionalColorTable.cs
- DictationGrammar.cs
- SiteMapSection.cs
- ActivationServices.cs
- InvalidCastException.cs
- HostedAspNetEnvironment.cs
- Win32SafeHandles.cs
- NamedPipeAppDomainProtocolHandler.cs
- RequestQueryParser.cs
- ComponentResourceManager.cs
- ColumnClickEvent.cs
- TextEditorTables.cs
- SqlDependency.cs
- TextDecorationCollectionConverter.cs
- ListViewItemEventArgs.cs
- SqlConnectionPoolGroupProviderInfo.cs
- Literal.cs
- HostVisual.cs
- PublisherIdentityPermission.cs
- DesignerTextBoxAdapter.cs
- Constraint.cs
- PropertyPath.cs