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
- AutomationPeer.cs
- XNameTypeConverter.cs
- ReliabilityContractAttribute.cs
- COM2PropertyBuilderUITypeEditor.cs
- GradientStopCollection.cs
- HttpApplicationStateBase.cs
- cryptoapiTransform.cs
- CachedPathData.cs
- NextPreviousPagerField.cs
- BamlTreeUpdater.cs
- DataGridPagerStyle.cs
- ListBoxItemWrapperAutomationPeer.cs
- CultureData.cs
- CachedCompositeFamily.cs
- Profiler.cs
- WindowsSlider.cs
- StructuredTypeEmitter.cs
- PropertyValueUIItem.cs
- LocatorManager.cs
- ExtensionSimplifierMarkupObject.cs
- MobileFormsAuthentication.cs
- HtmlElement.cs
- SchemaLookupTable.cs
- TempFiles.cs
- GroupQuery.cs
- OptimalTextSource.cs
- RectangleF.cs
- __Filters.cs
- DoubleIndependentAnimationStorage.cs
- ResourceProperty.cs
- CatalogPartCollection.cs
- FormattedTextSymbols.cs
- CheckBox.cs
- SqlUDTStorage.cs
- ConnectionManagementElement.cs
- DBPropSet.cs
- RefreshEventArgs.cs
- LogicalExpr.cs
- UrlPropertyAttribute.cs
- XamlReader.cs
- EmbossBitmapEffect.cs
- FileDetails.cs
- HMACSHA512.cs
- SecurityState.cs
- XamlTreeBuilder.cs
- Debug.cs
- Utils.cs
- FormsAuthentication.cs
- Profiler.cs
- RawStylusSystemGestureInputReport.cs
- ListParagraph.cs
- HelpKeywordAttribute.cs
- OdbcCommand.cs
- ElementInit.cs
- SettingsPropertyValue.cs
- EUCJPEncoding.cs
- GeneralTransformGroup.cs
- DataBinder.cs
- SignedInfo.cs
- IndexedString.cs
- DelimitedListTraceListener.cs
- StringOutput.cs
- ButtonField.cs
- EmbeddedMailObjectsCollection.cs
- DriveNotFoundException.cs
- newitemfactory.cs
- DocumentGridContextMenu.cs
- PlatformCulture.cs
- NegationPusher.cs
- CellNormalizer.cs
- TextDecoration.cs
- Span.cs
- NativeMethods.cs
- HttpCookiesSection.cs
- PlatformCulture.cs
- Oid.cs
- SelectionPattern.cs
- AmbiguousMatchException.cs
- Clause.cs
- LinearQuaternionKeyFrame.cs
- DataBinding.cs
- NamedObjectList.cs
- DbProviderSpecificTypePropertyAttribute.cs
- PnrpPermission.cs
- FormViewPageEventArgs.cs
- Version.cs
- CodeAccessPermission.cs
- ApplicationInfo.cs
- XmlSchemaValidator.cs
- MobileListItem.cs
- VisualBrush.cs
- FunctionGenerator.cs
- RenderContext.cs
- Input.cs
- Base64Stream.cs
- SQLSingle.cs
- ColumnTypeConverter.cs
- Primitive.cs
- LinkUtilities.cs
- SizeValueSerializer.cs