Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataEntity / System / Data / Objects / Internal / complextypematerializer.cs / 1305376 / complextypematerializer.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- using System.Data.Metadata.Edm; using System.Data.Common; using System.Diagnostics; using System.Data.Mapping; namespace System.Data.Objects.Internal { ////// Supports materialization of complex type instances from records. Used /// by the ObjectStateManager. /// internal class ComplexTypeMaterializer { private readonly MetadataWorkspace _workspace; private const int MaxPlanCount = 4; private Plan[] _lastPlans; private int _lastPlanIndex; internal ComplexTypeMaterializer(MetadataWorkspace workspace) { _workspace = workspace; } internal object CreateComplex(IExtendedDataRecord record, DataRecordInfo recordInfo, object result) { Debug.Assert(null != record, "null IExtendedDataRecord"); Debug.Assert(null != recordInfo, "null DataRecordInfo"); Debug.Assert(null != recordInfo.RecordType, "null TypeUsage"); Debug.Assert(null != recordInfo.RecordType.EdmType, "null EdmType"); Debug.Assert(Helper.IsEntityType(recordInfo.RecordType.EdmType) || Helper.IsComplexType(recordInfo.RecordType.EdmType), "not EntityType or ComplexType"); Plan plan = GetPlan(record, recordInfo); if (null == result) { result = ((Func
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- MouseOverProperty.cs
- ScriptingWebServicesSectionGroup.cs
- ListBox.cs
- XPathDescendantIterator.cs
- SqlRecordBuffer.cs
- MenuCommands.cs
- XmlToDatasetMap.cs
- DataGridViewAdvancedBorderStyle.cs
- bindurihelper.cs
- GeometryGroup.cs
- SortKey.cs
- EmbossBitmapEffect.cs
- JpegBitmapEncoder.cs
- DataObject.cs
- CommandBinding.cs
- EmptyEnumerator.cs
- DataContractSerializerSection.cs
- InstalledVoice.cs
- CallbackValidator.cs
- RepeatEnumerable.cs
- SecurityVersion.cs
- Menu.cs
- SHA1Cng.cs
- OpCellTreeNode.cs
- ObjectDataSourceMethodEventArgs.cs
- AccessDataSourceView.cs
- ArrayConverter.cs
- NativeWrapper.cs
- BooleanProjectedSlot.cs
- MetadataCacheItem.cs
- DataList.cs
- Simplifier.cs
- ListBoxAutomationPeer.cs
- Resources.Designer.cs
- Pair.cs
- BidPrivateBase.cs
- DataListItemCollection.cs
- AuthenticateEventArgs.cs
- hwndwrapper.cs
- DataControlLinkButton.cs
- UxThemeWrapper.cs
- TextTrailingCharacterEllipsis.cs
- _SingleItemRequestCache.cs
- TextBox.cs
- LocalBuilder.cs
- filewebresponse.cs
- TraceContextEventArgs.cs
- PenContexts.cs
- SrgsElement.cs
- NameNode.cs
- Registry.cs
- WmfPlaceableFileHeader.cs
- AppDomainUnloadedException.cs
- BinaryFormatter.cs
- DelayedRegex.cs
- ExecutionEngineException.cs
- Pointer.cs
- AmbientProperties.cs
- StringExpressionSet.cs
- IdentityHolder.cs
- AppDomainUnloadedException.cs
- CheckBoxList.cs
- X509Utils.cs
- ByteArrayHelperWithString.cs
- BindingManagerDataErrorEventArgs.cs
- XmlSchemaGroupRef.cs
- IOException.cs
- Dispatcher.cs
- BaseCollection.cs
- DataServiceRequestException.cs
- WebServiceResponseDesigner.cs
- ReverseComparer.cs
- Bitmap.cs
- AssemblyNameProxy.cs
- AttachedPropertyBrowsableForTypeAttribute.cs
- DiscoveryReference.cs
- figurelength.cs
- EncryptedPackage.cs
- XmlArrayItemAttributes.cs
- ClusterRegistryConfigurationProvider.cs
- AudioDeviceOut.cs
- ErrorTableItemStyle.cs
- RuntimeCompatibilityAttribute.cs
- _ContextAwareResult.cs
- TraceFilter.cs
- BlurBitmapEffect.cs
- Clause.cs
- _Semaphore.cs
- Win32Native.cs
- DeflateStreamAsyncResult.cs
- ArrayHelper.cs
- DescendentsWalker.cs
- TypeConverters.cs
- HtmlTableCell.cs
- MdiWindowListStrip.cs
- QilStrConcat.cs
- contentDescriptor.cs
- SliderAutomationPeer.cs
- LifetimeMonitor.cs
- DataBoundLiteralControl.cs