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
- RelationshipEndCollection.cs
- ExpressionBindingCollection.cs
- EntityProxyFactory.cs
- EditingCommands.cs
- AuthenticationException.cs
- ScriptReferenceEventArgs.cs
- PrintPreviewControl.cs
- TemplateBindingExpressionConverter.cs
- BitmapEffectInput.cs
- TrustManager.cs
- GeneratedContractType.cs
- InputBuffer.cs
- XmlDeclaration.cs
- SystemIPGlobalStatistics.cs
- ThicknessConverter.cs
- HandlerBase.cs
- KnownIds.cs
- DataListItemCollection.cs
- StaticExtensionConverter.cs
- CatalogPart.cs
- TextServicesManager.cs
- ErrorInfoXmlDocument.cs
- ForeignConstraint.cs
- RetrieveVirtualItemEventArgs.cs
- TextBreakpoint.cs
- SchemaInfo.cs
- PictureBox.cs
- RelationshipEndMember.cs
- ControlValuePropertyAttribute.cs
- DataViewSettingCollection.cs
- DecimalConverter.cs
- TreeView.cs
- _FtpControlStream.cs
- X509Chain.cs
- OdbcConnectionOpen.cs
- CellParagraph.cs
- GridViewRowPresenter.cs
- Separator.cs
- QuaternionAnimation.cs
- RoleServiceManager.cs
- SessionEndingCancelEventArgs.cs
- EncodingDataItem.cs
- UseManagedPresentationBindingElement.cs
- IdleTimeoutMonitor.cs
- ObjectDisposedException.cs
- RegexCompilationInfo.cs
- MatrixStack.cs
- CoTaskMemHandle.cs
- X509Utils.cs
- MdImport.cs
- QilFunction.cs
- WeakReferenceList.cs
- GridViewRow.cs
- SamlAuthenticationClaimResource.cs
- BlobPersonalizationState.cs
- KeyEvent.cs
- PropertyDescriptor.cs
- PathFigureCollection.cs
- OperationAbortedException.cs
- ManualWorkflowSchedulerService.cs
- GridViewCommandEventArgs.cs
- FacetDescriptionElement.cs
- InvokeSchedule.cs
- Int16Converter.cs
- PropertyItemInternal.cs
- FlowNode.cs
- SystemColorTracker.cs
- BasicHttpBinding.cs
- ProcessInputEventArgs.cs
- GenerateScriptTypeAttribute.cs
- MenuItem.cs
- GenericsInstances.cs
- SqlXmlStorage.cs
- MsmqIntegrationProcessProtocolHandler.cs
- ResolveNameEventArgs.cs
- WebPartZoneCollection.cs
- DynamicPropertyHolder.cs
- FileDialogPermission.cs
- StyleXamlParser.cs
- CodePrimitiveExpression.cs
- Slider.cs
- DataViewManagerListItemTypeDescriptor.cs
- ConsumerConnectionPoint.cs
- TypeReference.cs
- HttpInputStream.cs
- SingleBodyParameterMessageFormatter.cs
- PrintControllerWithStatusDialog.cs
- WindowsRegion.cs
- MetadataItemCollectionFactory.cs
- DesignerDataSourceView.cs
- RootDesignerSerializerAttribute.cs
- XmlStreamNodeWriter.cs
- TdsParserSafeHandles.cs
- TraceRecords.cs
- InkCanvasFeedbackAdorner.cs
- RecommendedAsConfigurableAttribute.cs
- EntityDesignerDataSourceView.cs
- CombinedHttpChannel.cs
- SortKey.cs
- SiteMap.cs