Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / NetFx35 / System.WorkflowServices / System / Workflow / Activities / ReceiveContext.cs / 1305376 / ReceiveContext.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.Workflow.Activities { using System; using System.Collections; using System.Collections.Generic; using System.Collections.Specialized; using System.ComponentModel; using System.Diagnostics.CodeAnalysis; using System.ServiceModel; using System.Xml; using System.ServiceModel.Dispatcher; [Serializable] internal sealed class ReceiveContext { static string emptyGuid = Guid.Empty.ToString(); Guid contextId = Guid.Empty; bool initialized = false; bool isRootContext = false; string name = null; SerializableReadOnlyDictionaryproperties = null; string workflowId = emptyGuid; public ReceiveContext(string name, Guid workflowId, bool isRootContext) { this.name = name; this.workflowId = workflowId.ToString(); this.isRootContext = isRootContext; } [Browsable(false)] public bool Initialized { get { return this.initialized; } } [Browsable(false)] public string Name { get { return this.name; } } [Browsable(false)] internal SerializableReadOnlyDictionary Properties { get { return this.properties; } } public void EnsureInitialized(Guid contextId) { if (this.contextId != contextId) { this.initialized = false; this.contextId = contextId; } if (this.Initialized) { return; } if (!isRootContext) { this.properties = new SerializableReadOnlyDictionary ( new KeyValuePair (WellKnownContextProperties.InstanceId, workflowId), new KeyValuePair (WellKnownContextProperties.ConversationId, Guid.NewGuid().ToString())); } else { this.properties = new SerializableReadOnlyDictionary ( new KeyValuePair (WellKnownContextProperties.InstanceId, workflowId)); } this.initialized = true; } } } // 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
- TdsParserStateObject.cs
- SchemaMerger.cs
- MoveSizeWinEventHandler.cs
- _ConnectStream.cs
- DataGridViewToolTip.cs
- DescendantQuery.cs
- SizeF.cs
- DataListItem.cs
- ReadOnlyNameValueCollection.cs
- SchemaImporter.cs
- securitymgrsite.cs
- KernelTypeValidation.cs
- PKCS1MaskGenerationMethod.cs
- OleDbParameter.cs
- GlobalizationSection.cs
- QuadraticBezierSegment.cs
- OdbcUtils.cs
- XmlILOptimizerVisitor.cs
- CachedBitmap.cs
- MachineKeyConverter.cs
- DrawToolTipEventArgs.cs
- ProfilePropertySettingsCollection.cs
- TreeNodeCollection.cs
- TCPListener.cs
- SiteMapNode.cs
- _NegotiateClient.cs
- CellTreeNodeVisitors.cs
- SynchronizationFilter.cs
- LayoutInformation.cs
- StreamResourceInfo.cs
- PrivilegedConfigurationManager.cs
- ServiceContractAttribute.cs
- ContentPresenter.cs
- IdentifierCollection.cs
- CodePrimitiveExpression.cs
- BamlLocalizableResourceKey.cs
- AsymmetricSignatureDeformatter.cs
- ByteStream.cs
- TimeIntervalCollection.cs
- QuaternionRotation3D.cs
- ImageInfo.cs
- NativeMethods.cs
- SqlDeflator.cs
- ConfigXmlWhitespace.cs
- ToolStripArrowRenderEventArgs.cs
- RecordManager.cs
- UnaryNode.cs
- ManifestSignatureInformation.cs
- CommentEmitter.cs
- AuthenticationService.cs
- RadioButtonRenderer.cs
- Dictionary.cs
- IsolatedStorageFile.cs
- GC.cs
- ParamArrayAttribute.cs
- Padding.cs
- Empty.cs
- SQLInt16.cs
- MouseActionValueSerializer.cs
- CompensableActivity.cs
- ServicePoint.cs
- GridViewUpdatedEventArgs.cs
- StreamUpdate.cs
- JournalNavigationScope.cs
- ScrollBar.cs
- EntityDesignerUtils.cs
- sqlmetadatafactory.cs
- TableLayoutSettingsTypeConverter.cs
- DataGridColumn.cs
- DataGridCellItemAutomationPeer.cs
- ArrangedElement.cs
- ReadOnlyTernaryTree.cs
- VisualStateChangedEventArgs.cs
- DrawingContext.cs
- OperationCanceledException.cs
- GlyphRunDrawing.cs
- ExpressionBuilder.cs
- pingexception.cs
- FocusChangedEventArgs.cs
- VirtualizingPanel.cs
- AliasedSlot.cs
- HostedTransportConfigurationManager.cs
- TextMetrics.cs
- FontDriver.cs
- FrameworkContextData.cs
- Typeface.cs
- TypefaceMap.cs
- JavaScriptString.cs
- NTAccount.cs
- SettingsPropertyCollection.cs
- GenerateTemporaryTargetAssembly.cs
- ServerValidateEventArgs.cs
- FillErrorEventArgs.cs
- HandlerWithFactory.cs
- XmlLangPropertyAttribute.cs
- TogglePattern.cs
- ObjectItemCollectionAssemblyCacheEntry.cs
- CompleteWizardStep.cs
- ImportContext.cs
- Label.cs