Share via


DispatchSource.SignalMonitor Class

Definition

Sources of this type monitor signals delivered to the current process.

public class DispatchSource.SignalMonitor : CoreFoundation.DispatchSource
type DispatchSource.SignalMonitor = class
    inherit DispatchSource
Inheritance

Remarks

Unlike signal handlers specified via sigaction(), the execution of the event handler block does not interrupt the current thread of execution; therefore the handler block is not limited to the use of signal safe interfaces defined in sigaction(2).  Furthermore, multiple observers of a given signal are supported; thus allowing applications and libraries to cooperate safely. However, a dispatch source does not install a signal handler or otherwise alter the behavior of signal delivery.  Therefore, applications must ignore or at least catch any signal that terminates a process by default.

Constructors

Name Description
DispatchSource.SignalMonitor(Int32, DispatchQueue)

Creates a process signal monitor

DispatchSource.SignalMonitor(IntPtr, Boolean)
DispatchSource.SignalMonitor(IntPtr)

Properties

Name Description
Handle (Inherited from DisposableObject)
IsCanceled

Determine whether the specified source has been canceled.

(Inherited from DispatchSource)
Owns (Inherited from DisposableObject)
SignalNumber
SignalsDelivered

The number of signals received since the last invocation of the event handler.

Methods

Name Description
Activate() (Inherited from DispatchObject)
Cancel()

Asynchronously cancels the dispatch source.

(Inherited from DispatchSource)
ClearHandle() (Inherited from DisposableObject)
Dispose() (Inherited from DisposableObject)
Dispose(Boolean)

Releases the resources used by the DispatchSource object.

(Inherited from DispatchSource)
Equals(Object) (Inherited from DisposableObject)
GetCheckedHandle() (Inherited from DisposableObject)
GetHashCode() (Inherited from DisposableObject)
InitializeHandle(NativeHandle) (Inherited from DisposableObject)
Release() (Inherited from DispatchObject)
Resume()

Resumes the dispatch source.

(Inherited from DispatchSource)
Retain() (Inherited from DispatchObject)
SetCancelHandler(Action)

Provides a cancellation handler

(Inherited from DispatchSource)
SetEventHandler(Action)

Specified a handler to execute when events are received on the dispatch source.

(Inherited from DispatchSource)
SetRegistrationHandler(Action)

Provides a registration handler

(Inherited from DispatchSource)
SetTargetQueue(DispatchQueue) (Inherited from DispatchObject)
Suspend()

Suspends the dispatch source.

(Inherited from DispatchSource)

Extension Methods

Name Description
GetHandle(INativeObject)
GetNonNullHandle(INativeObject, String)

Applies to