Skip to content

CurrentThreadSequencer.Schedule(Action) method

Defined in

Type: CurrentThreadSequencer Namespace: ReactiveUI.Primitives.Concurrency Assembly: ReactiveUI.Primitives.dll

Applies to

net10.0, net10.0-android36.0, net10.0-ios26.0, net10.0-macos26.0, net10.0-tvos26.0, net10.0-maccatalyst26.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-desktop1.0, net9.0-browserwasm1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, net481, net471, net462

Overloads

  • 1. public IDisposable Schedule(Action action)
  • 2. public void Schedule(IWorkItem item)
  • 3. public void Schedule(IWorkItem item, long dueTimestamp)

1. Overload

public IDisposable Schedule(Action action)

View source

Summary: Schedules an action to be executed on the current-thread trampoline.

Parameters

NameTypeDescription
actionActionAction to execute.

Returns: IDisposable -- The disposable object used to cancel queued work, or an empty disposable when the action has already run.

Exceptions

TypeCondition
System.ArgumentNullExceptionaction is null.

2. Overload

public void Schedule(IWorkItem item)

View source

Summary: Schedules a work item to be executed.

Parameters

NameTypeDescription
item[IWorkItem](#Work item to execute.

Exceptions

TypeCondition
System.ArgumentNullExceptionitem is null.

3. Overload

public void Schedule(IWorkItem item, long dueTimestamp)

View source

Summary: Schedules a work item to be executed at the specified monotonic timestamp.

Parameters

NameTypeDescription
item[IWorkItem](#Work item to execute.
dueTimestamplongAbsolute monotonic timestamp at which to execute the item.

Exceptions

TypeCondition
System.ArgumentNullExceptionitem is null.