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
- InvokeDelegate.cs
- ConsoleTraceListener.cs
- FloaterBaseParagraph.cs
- AuthorizationRuleCollection.cs
- ServiceOperationListItem.cs
- CodeThrowExceptionStatement.cs
- StackOverflowException.cs
- ReflectTypeDescriptionProvider.cs
- ObjectView.cs
- DbDataAdapter.cs
- ObjectItemCollectionAssemblyCacheEntry.cs
- SafeFileMappingHandle.cs
- WindowsAuthenticationEventArgs.cs
- ContainerControl.cs
- SizeAnimationClockResource.cs
- MetadataItemEmitter.cs
- HtmlControl.cs
- CmsInterop.cs
- WindowAutomationPeer.cs
- XmlSchemaSimpleTypeRestriction.cs
- ClientSession.cs
- ViewUtilities.cs
- PrimitiveRenderer.cs
- RootBrowserWindowAutomationPeer.cs
- Privilege.cs
- Rect3DConverter.cs
- CodeMemberField.cs
- HeaderCollection.cs
- ErrorHandler.cs
- SmtpAuthenticationManager.cs
- DataListItem.cs
- SerialStream.cs
- CompensatableTransactionScopeActivityDesigner.cs
- AppDomain.cs
- AvtEvent.cs
- SHA256Managed.cs
- EncoderExceptionFallback.cs
- InputScope.cs
- ReadOnlyCollection.cs
- XmlSchemaCompilationSettings.cs
- OleDbConnectionInternal.cs
- Msec.cs
- CommandEventArgs.cs
- sqlpipe.cs
- DetailsViewInsertedEventArgs.cs
- OdbcStatementHandle.cs
- ClientUrlResolverWrapper.cs
- ConstructorArgumentAttribute.cs
- FormsAuthenticationUserCollection.cs
- RSACryptoServiceProvider.cs
- ContractListAdapter.cs
- WorkflowApplicationCompletedException.cs
- SpeechDetectedEventArgs.cs
- WebExceptionStatus.cs
- _AcceptOverlappedAsyncResult.cs
- Int64Animation.cs
- EdmProviderManifest.cs
- DataGridViewEditingControlShowingEventArgs.cs
- ReflectPropertyDescriptor.cs
- TextSelectionHelper.cs
- MDIControlStrip.cs
- TcpAppDomainProtocolHandler.cs
- SerializationInfoEnumerator.cs
- Stack.cs
- LocationEnvironment.cs
- XmlDataCollection.cs
- _Connection.cs
- SHA384Managed.cs
- NetworkInterface.cs
- XDRSchema.cs
- DropDownList.cs
- ListItemCollection.cs
- CellLabel.cs
- RijndaelManaged.cs
- UserUseLicenseDictionaryLoader.cs
- DataSpaceManager.cs
- DataObjectMethodAttribute.cs
- Helpers.cs
- Constraint.cs
- TypeDescriptor.cs
- DependencySource.cs
- SuspendDesigner.cs
- EntityDataSource.cs
- CodeEntryPointMethod.cs
- DependencyPropertyDescriptor.cs
- PolyQuadraticBezierSegment.cs
- PerformanceCounterPermission.cs
- ConstraintCollection.cs
- SignatureToken.cs
- XmlWriter.cs
- TypeDescriptorContext.cs
- SqlAliasesReferenced.cs
- ChineseLunisolarCalendar.cs
- GC.cs
- SystemException.cs
- AspNetSynchronizationContext.cs
- sqlstateclientmanager.cs
- TemplatedControlDesigner.cs
- FileLoadException.cs
- CompatibleIComparer.cs