Table of Contents

Class MacOSSynchronizationContext

Namespace
Xui.Runtime.MacOS.Actual
Assembly
Xui.Runtime.MacOS.dll
public class MacOSSynchronizationContext : SynchronizationContext
Inheritance
MacOSSynchronizationContext
Inherited Members

Constructors

MacOSSynchronizationContext(MacOSRunLoop)

public MacOSSynchronizationContext(MacOSRunLoop macOSRunLoop)

Parameters

macOSRunLoop MacOSRunLoop

Methods

CreateCopy()

When overridden in a derived class, creates a copy of the synchronization context.

public override SynchronizationContext CreateCopy()

Returns

SynchronizationContext

A new SynchronizationContext object.

OperationCompleted()

When overridden in a derived class, responds to the notification that an operation has completed.

public override void OperationCompleted()

OperationStarted()

When overridden in a derived class, responds to the notification that an operation has started.

public override void OperationStarted()

Post(SendOrPostCallback, object?)

When overridden in a derived class, dispatches an asynchronous message to a synchronization context.

public override void Post(SendOrPostCallback d, object? state)

Parameters

d SendOrPostCallback

The SendOrPostCallback delegate to call.

state object

The object passed to the delegate.

Send(SendOrPostCallback, object?)

When overridden in a derived class, dispatches a synchronous message to a synchronization context.

public override void Send(SendOrPostCallback d, object? state)

Parameters

d SendOrPostCallback

The SendOrPostCallback delegate to call.

state object

The object passed to the delegate.

Exceptions

NotSupportedException

The method was called in a Windows Store app. The implementation of SynchronizationContext for Windows Store apps does not support the Send(SendOrPostCallback, object) method.

Wait(nint[], bool, int)

Waits for any or all the elements in the specified array to receive a signal.

public override int Wait(nint[] waitHandles, bool waitAll, int millisecondsTimeout)

Parameters

waitHandles nint[]

An array of type nint that contains the native operating system handles.

waitAll bool

true to wait for all handles; false to wait for any handle.

millisecondsTimeout int

The number of milliseconds to wait, or Infinite (-1) to wait indefinitely.

Returns

int

The array index of the object that satisfied the wait.

Exceptions

ArgumentNullException

waitHandles is null.