Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / Activities / LocalService / FollowerQueueCreator.cs / 1305376 / FollowerQueueCreator.cs
#region Using directives using System; using System.Diagnostics; using System.Collections.Generic; using System.Collections; using System.Reflection; using System.Runtime.Serialization; using System.Workflow.ComponentModel; using System.Workflow.Runtime; using System.Workflow.Runtime.Hosting; using System.Runtime.Remoting.Messaging; #endregion namespace System.Workflow.Activities { [Serializable] internal sealed class FollowerQueueCreator : IActivityEventListener{ string followerOperation; object [....] = new object(); internal FollowerQueueCreator(string operation) { this.followerOperation = operation; } public override bool Equals(object obj) { if (obj == null) return false; FollowerQueueCreator equalsObject = obj as FollowerQueueCreator; if (this.followerOperation == equalsObject.followerOperation) return true; return false; } public override int GetHashCode() { return this.followerOperation.GetHashCode(); } #region IActivityEventListener Members void IActivityEventListener .OnEvent(object sender, QueueEventArgs args) { lock ([....]) { WorkflowQueue queue = (WorkflowQueue)sender; // create the queue after extracting the correlation values from the message EventQueueName staticId = (EventQueueName)queue.QueueName; WorkflowActivityTrace.Activity.TraceEvent(TraceEventType.Information, 0, "FollowerQueueCreator: initialized on operation {0} for follower {1}", staticId.InterfaceType.Name + staticId.MethodName, this.followerOperation); IMethodMessage message = queue.Peek() as IMethodMessage; ICollection corrValues = CorrelationResolver.ResolveCorrelationValues(staticId.InterfaceType, staticId.MethodName, message.Args, false); EventQueueName queueName = new EventQueueName(staticId.InterfaceType, this.followerOperation, corrValues); if (!queue.QueuingService.Exists(queueName)) { WorkflowActivityTrace.Activity.TraceEvent(TraceEventType.Information, 0, "FollowerQueueCreator::CreateQueue creating q {0}", queueName.GetHashCode()); queue.QueuingService.CreateWorkflowQueue(queueName, true); } } } #endregion } } // 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
- CodeDomDecompiler.cs
- InvalidCastException.cs
- HttpRequestWrapper.cs
- HttpContextWrapper.cs
- CodeGotoStatement.cs
- DataColumnChangeEvent.cs
- StaticExtensionConverter.cs
- ADMembershipUser.cs
- MarkupExtensionParser.cs
- DataList.cs
- WindowsSlider.cs
- UserNameSecurityTokenProvider.cs
- ReferencedAssembly.cs
- SQLRoleProvider.cs
- Transform.cs
- ContentIterators.cs
- SqlUserDefinedAggregateAttribute.cs
- control.ime.cs
- NotCondition.cs
- WebPartManagerInternals.cs
- ControlPropertyNameConverter.cs
- CryptoConfig.cs
- HashCryptoHandle.cs
- HttpWebResponse.cs
- CollectionViewGroupRoot.cs
- ServerIdentity.cs
- AuthorizationRuleCollection.cs
- ToolStripDropDownClosingEventArgs.cs
- NativeCompoundFileAPIs.cs
- WindowsGraphicsWrapper.cs
- CrossAppDomainChannel.cs
- ListDictionary.cs
- FillBehavior.cs
- ProcessModelSection.cs
- ToolboxItemCollection.cs
- TextRunCacheImp.cs
- ClientTargetCollection.cs
- DataGridItemEventArgs.cs
- FilePrompt.cs
- AttachedPropertyBrowsableForTypeAttribute.cs
- ProfileInfo.cs
- HitTestParameters3D.cs
- ManagementExtension.cs
- RelationshipEnd.cs
- RolePrincipal.cs
- DBDataPermissionAttribute.cs
- Fonts.cs
- DependencyPropertyKind.cs
- RangeEnumerable.cs
- MissingMethodException.cs
- Attributes.cs
- RequestQueue.cs
- RecordManager.cs
- CharacterShapingProperties.cs
- VersionedStreamOwner.cs
- StrokeRenderer.cs
- OciHandle.cs
- BindingMAnagerBase.cs
- AddDataControlFieldDialog.cs
- SoapInteropTypes.cs
- CapacityStreamGeometryContext.cs
- RoleManagerEventArgs.cs
- SamlDoNotCacheCondition.cs
- ConfigurationSettings.cs
- CompilerTypeWithParams.cs
- Not.cs
- RuntimeEnvironment.cs
- safelink.cs
- Dump.cs
- PropertyGridCommands.cs
- PathData.cs
- RootBrowserWindow.cs
- CellRelation.cs
- AssemblyInfo.cs
- VirtualizingStackPanel.cs
- SelectorAutomationPeer.cs
- WebPartPersonalization.cs
- HelpKeywordAttribute.cs
- ListBindingHelper.cs
- OciEnlistContext.cs
- DmlSqlGenerator.cs
- SqlCharStream.cs
- StateMachineWorkflow.cs
- AnonymousIdentificationModule.cs
- StateMachine.cs
- DataGridBoolColumn.cs
- NonBatchDirectoryCompiler.cs
- ManagementOperationWatcher.cs
- HwndSource.cs
- SettingsPropertyNotFoundException.cs
- ObjectViewEntityCollectionData.cs
- comcontractssection.cs
- DataTableTypeConverter.cs
- PropertyEntry.cs
- FormsAuthenticationTicket.cs
- FontFamily.cs
- ProtectedConfiguration.cs
- odbcmetadatacolumnnames.cs
- ControlDesigner.cs
- UserControlFileEditor.cs