Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / RunTime / Hosting / WorkflowTimerService.cs / 1305376 / WorkflowTimerService.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- using System.Workflow.ComponentModel; using System.Workflow.Runtime; using System.Threading; namespace System.Workflow.Runtime.Hosting { class WorkflowTimerService : WorkflowRuntimeService, ITimerService { public WorkflowTimerService() : base() { } public void ScheduleTimer(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId) { WorkflowSchedulerService schedulerService = this.Runtime.GetService(typeof(WorkflowSchedulerService)) as WorkflowSchedulerService; schedulerService.Schedule(callback, workflowInstanceId, whenUtc, timerId); } public void CancelTimer(Guid timerId) { WorkflowSchedulerService schedulerService = this.Runtime.GetService(typeof(WorkflowSchedulerService)) as WorkflowSchedulerService; schedulerService.Cancel(timerId); } } } // 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.Workflow.ComponentModel; using System.Workflow.Runtime; using System.Threading; namespace System.Workflow.Runtime.Hosting { class WorkflowTimerService : WorkflowRuntimeService, ITimerService { public WorkflowTimerService() : base() { } public void ScheduleTimer(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId) { WorkflowSchedulerService schedulerService = this.Runtime.GetService(typeof(WorkflowSchedulerService)) as WorkflowSchedulerService; schedulerService.Schedule(callback, workflowInstanceId, whenUtc, timerId); } public void CancelTimer(Guid timerId) { WorkflowSchedulerService schedulerService = this.Runtime.GetService(typeof(WorkflowSchedulerService)) as WorkflowSchedulerService; schedulerService.Cancel(timerId); } } } // 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
- FrameworkElementFactory.cs
- XomlDesignerLoader.cs
- Menu.cs
- ListItem.cs
- BoolExpressionVisitors.cs
- AuthenticationModuleElement.cs
- DbExpressionRules.cs
- XmlImplementation.cs
- StorageComplexTypeMapping.cs
- XslAst.cs
- OperationInfo.cs
- codemethodreferenceexpression.cs
- ShapingEngine.cs
- PersonalizationProviderCollection.cs
- CultureInfoConverter.cs
- GPStream.cs
- SqlNode.cs
- RecommendedAsConfigurableAttribute.cs
- StorageEntityContainerMapping.cs
- ConfigurationManagerInternalFactory.cs
- SessionChannels.cs
- WebMessageEncodingElement.cs
- ClosableStream.cs
- DebuggerAttributes.cs
- BindingsCollection.cs
- TreeViewImageKeyConverter.cs
- AmbiguousMatchException.cs
- DetailsViewUpdateEventArgs.cs
- Pair.cs
- SparseMemoryStream.cs
- KeyFrames.cs
- ICspAsymmetricAlgorithm.cs
- DataGridViewRowStateChangedEventArgs.cs
- TextParagraphProperties.cs
- ReferenceEqualityComparer.cs
- SqlDesignerDataSourceView.cs
- XmlResolver.cs
- XmlWrappingReader.cs
- CookieParameter.cs
- WriterOutput.cs
- AssemblyCache.cs
- UrlMappingsModule.cs
- XmlAnyElementAttributes.cs
- SystemUdpStatistics.cs
- PreviewKeyDownEventArgs.cs
- StylusButtonEventArgs.cs
- HtmlInputHidden.cs
- GridViewColumnCollectionChangedEventArgs.cs
- MarginCollapsingState.cs
- PhysicalAddress.cs
- AttributeQuery.cs
- PackageRelationship.cs
- Header.cs
- tibetanshape.cs
- ResXDataNode.cs
- BoundsDrawingContextWalker.cs
- SQLBinary.cs
- ListBox.cs
- SafeCryptoHandles.cs
- DesignerObject.cs
- HwndHostAutomationPeer.cs
- NameObjectCollectionBase.cs
- WindowsFormsSectionHandler.cs
- UrlMappingsSection.cs
- WaitForChangedResult.cs
- Emitter.cs
- EntityPropertyMappingAttribute.cs
- StaticFileHandler.cs
- HwndTarget.cs
- EntityDataSourceContainerNameItem.cs
- UdpChannelFactory.cs
- BlobPersonalizationState.cs
- ProcessModelSection.cs
- SQLMoneyStorage.cs
- EncoderReplacementFallback.cs
- smtppermission.cs
- SqlNodeAnnotations.cs
- CornerRadius.cs
- StandardCommandToolStripMenuItem.cs
- SqlEnums.cs
- basevalidator.cs
- ControlValuePropertyAttribute.cs
- SigningProgress.cs
- PublisherMembershipCondition.cs
- XmlAtomicValue.cs
- SpellCheck.cs
- SpeakProgressEventArgs.cs
- XmlQueryContext.cs
- AbsoluteQuery.cs
- MouseGesture.cs
- VirtualDirectoryMappingCollection.cs
- MSAAEventDispatcher.cs
- OracleConnectionString.cs
- ServicePoint.cs
- PageParserFilter.cs
- WebBrowser.cs
- DataGridrowEditEndingEventArgs.cs
- SrgsElementList.cs
- WebPartConnectVerb.cs
- SqlConnectionPoolGroupProviderInfo.cs