TimerEventSubscriptionCollection.Add(TimerEventSubscription) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
會把 a TimerEventSubscription 加入計時器佇列。
public:
void Add(System::Workflow::Runtime::TimerEventSubscription ^ item);
public void Add(System.Workflow.Runtime.TimerEventSubscription item);
member this.Add : System.Workflow.Runtime.TimerEventSubscription -> unit
Public Sub Add (item As TimerEventSubscription)
參數
TimerEventSubscription要加入計時器佇列。
例外狀況
備註
會把 加入 TimerEventSubscription 計時器佇列。 排隊中的訂閱會根據其 TimerEventSubscription.ExpiresAt 數值來定位;價值較小的則排在較大的訂閱前方。 如果新訂閱在佇列 WorkflowSchedulerService.Cancel 開始時加入,會被呼叫來取消原本在佇列開始時的計時器事件,並 WorkflowSchedulerService.Schedule(WaitCallback, Guid, DateTime, Guid) 被呼叫來排程新的計時器事件。 Add 在新增訂閱前鎖定 , TimerEventSubscriptionCollection 因此是安全的。