Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / System.Runtime.DurableInstancing / System / Runtime / DurableInstancing / InstanceKeyView.cs / 1305376 / InstanceKeyView.cs
//---------------------------------------------------------------- // Copyright (c) Microsoft Corporation. All rights reserved. //--------------------------------------------------------------- namespace System.Runtime.DurableInstancing { using System; using System.Collections.Generic; using System.Runtime; using System.Xml.Linq; [Fx.Tag.XamlVisible(false)] public sealed class InstanceKeyView { static readonly ReadOnlyDictionaryemptyProperties = new ReadOnlyDictionary (new Dictionary (0), false); IDictionary metadata; Dictionary accumulatedMetadataWrites; internal InstanceKeyView(Guid key) { InstanceKey = key; InstanceKeyMetadataConsistency = InstanceValueConsistency.InDoubt | InstanceValueConsistency.Partial; } InstanceKeyView(InstanceKeyView source) { InstanceKey = source.InstanceKey; InstanceKeyState = source.InstanceKeyState; InstanceKeyMetadata = source.InstanceKeyMetadata; InstanceKeyMetadataConsistency = source.InstanceKeyMetadataConsistency; } public Guid InstanceKey { get; private set; } public InstanceKeyState InstanceKeyState { get; internal set; } public InstanceValueConsistency InstanceKeyMetadataConsistency { get; internal set; } public IDictionary InstanceKeyMetadata { get { IDictionary pendingWrites = this.accumulatedMetadataWrites; this.accumulatedMetadataWrites = null; this.metadata = pendingWrites.ReadOnlyMergeInto(this.metadata ?? InstanceKeyView.emptyProperties, true); return this.metadata; } internal set { this.accumulatedMetadataWrites = null; this.metadata = value; } } internal Dictionary AccumulatedMetadataWrites { get { if (this.accumulatedMetadataWrites == null) { this.accumulatedMetadataWrites = new Dictionary (); } return this.accumulatedMetadataWrites; } } internal InstanceKeyView Clone() { return new InstanceKeyView(this); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //---------------------------------------------------------------- // Copyright (c) Microsoft Corporation. All rights reserved. //--------------------------------------------------------------- namespace System.Runtime.DurableInstancing { using System; using System.Collections.Generic; using System.Runtime; using System.Xml.Linq; [Fx.Tag.XamlVisible(false)] public sealed class InstanceKeyView { static readonly ReadOnlyDictionary emptyProperties = new ReadOnlyDictionary (new Dictionary (0), false); IDictionary metadata; Dictionary accumulatedMetadataWrites; internal InstanceKeyView(Guid key) { InstanceKey = key; InstanceKeyMetadataConsistency = InstanceValueConsistency.InDoubt | InstanceValueConsistency.Partial; } InstanceKeyView(InstanceKeyView source) { InstanceKey = source.InstanceKey; InstanceKeyState = source.InstanceKeyState; InstanceKeyMetadata = source.InstanceKeyMetadata; InstanceKeyMetadataConsistency = source.InstanceKeyMetadataConsistency; } public Guid InstanceKey { get; private set; } public InstanceKeyState InstanceKeyState { get; internal set; } public InstanceValueConsistency InstanceKeyMetadataConsistency { get; internal set; } public IDictionary InstanceKeyMetadata { get { IDictionary pendingWrites = this.accumulatedMetadataWrites; this.accumulatedMetadataWrites = null; this.metadata = pendingWrites.ReadOnlyMergeInto(this.metadata ?? InstanceKeyView.emptyProperties, true); return this.metadata; } internal set { this.accumulatedMetadataWrites = null; this.metadata = value; } } internal Dictionary AccumulatedMetadataWrites { get { if (this.accumulatedMetadataWrites == null) { this.accumulatedMetadataWrites = new Dictionary (); } return this.accumulatedMetadataWrites; } } internal InstanceKeyView Clone() { return new InstanceKeyView(this); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SQLChars.cs
- Stylus.cs
- WebPartDescriptionCollection.cs
- ClonableStack.cs
- FileAuthorizationModule.cs
- XmlSerializerOperationFormatter.cs
- ArgIterator.cs
- ReflectPropertyDescriptor.cs
- SourceLocation.cs
- PolyQuadraticBezierSegment.cs
- EncoderReplacementFallback.cs
- MessageFilter.cs
- XPathNode.cs
- CodeSubDirectory.cs
- DependencyObject.cs
- ServicePoint.cs
- FieldAccessException.cs
- SafeNativeMethods.cs
- QuaternionRotation3D.cs
- XmlWhitespace.cs
- LayoutEngine.cs
- SHA1CryptoServiceProvider.cs
- DataColumnMapping.cs
- NoneExcludedImageIndexConverter.cs
- CorrelationTokenTypeConvertor.cs
- BindingNavigator.cs
- DoubleAnimationUsingKeyFrames.cs
- TiffBitmapEncoder.cs
- SmiGettersStream.cs
- ImageSourceConverter.cs
- FileRecordSequenceCompletedAsyncResult.cs
- CommonGetThemePartSize.cs
- TextContainerChangedEventArgs.cs
- VectorValueSerializer.cs
- WebPartConnectionsDisconnectVerb.cs
- CustomAttributeSerializer.cs
- SerialStream.cs
- FixedPage.cs
- RectConverter.cs
- DiscoveryInnerClientManaged11.cs
- GridLengthConverter.cs
- AddInControllerImpl.cs
- ClientBuildManager.cs
- BufferAllocator.cs
- IntSecurity.cs
- XmlSchemaInclude.cs
- ArrangedElement.cs
- KoreanLunisolarCalendar.cs
- WebRequestModuleElementCollection.cs
- WindowsRegion.cs
- CodeAccessSecurityEngine.cs
- VectorConverter.cs
- DataGridViewColumnConverter.cs
- RayHitTestParameters.cs
- QueryOperator.cs
- MobileControlsSectionHelper.cs
- MemberDescriptor.cs
- DecoderFallback.cs
- HMAC.cs
- MetafileHeaderWmf.cs
- GridViewHeaderRowPresenterAutomationPeer.cs
- QuaternionRotation3D.cs
- TableRow.cs
- Soap.cs
- XmlILOptimizerVisitor.cs
- CallInfo.cs
- FontSource.cs
- AssemblyAttributesGoHere.cs
- SqlCacheDependencyDatabaseCollection.cs
- IdleTimeoutMonitor.cs
- SendMailErrorEventArgs.cs
- StylusPlugin.cs
- TypographyProperties.cs
- ColorBlend.cs
- MethodBody.cs
- Rotation3DAnimationBase.cs
- PerSessionInstanceContextProvider.cs
- DynamicControl.cs
- FragmentQuery.cs
- CodeDirectoryCompiler.cs
- CompositeDispatchFormatter.cs
- DelayedRegex.cs
- SudsWriter.cs
- TreeNode.cs
- X509Extension.cs
- SignatureGenerator.cs
- ListDictionaryInternal.cs
- XmlIlGenerator.cs
- KeyGestureConverter.cs
- AbstractSvcMapFileLoader.cs
- EditorPart.cs
- MessageFormatterConverter.cs
- NonBatchDirectoryCompiler.cs
- NativeMethods.cs
- ParameterToken.cs
- Tablet.cs
- CodeEntryPointMethod.cs
- XmlSchemaExternal.cs
- Form.cs
- SoapAttributeAttribute.cs