Instance Propertynmggithub.kass 3.2.4MachCore
mask
The mask of the exception types that the port will catch.
let mask: Mach.ExceptionMask
The mask of the exception types that the port will catch.
let mask: Mach.ExceptionMask
import MachCore
The core module for interacting with the Mach kernel.
class ExceptionPort
An exception port.
struct Mach
The Mach kernel.
struct ExceptionMask
A mask for getting or setting exception ports.
init(named name: mach_port_name_t, mask: Mach.ExceptionMask = .all, behavior: Mach.ExceptionBehavior = .default, threadStateFlavor: Mach.ThreadStateFlavor = .none)
Creates an exception port.
static func addExceptionPort(_ port: Mach.ExceptionPort, toHost host: Mach.Host) throws
Adds an exception port to the host.
static func addExceptionPort(_ port: Mach.ExceptionPort, toTask task: Mach.Task) throws
Adds an exception port to the task.
static func addExceptionPort(_ port: Mach.ExceptionPort, toThread thread: Mach.Thread) throws
Adds an exception port to the thread.
static func exceptionPorts(forHost host: Mach.Host, mask: Mach.ExceptionMask) throws -> [Mach.ExceptionPort]
Gets the exception ports for the host that catch the exception types specified by the mask.
static func exceptionPorts(forTask task: Mach.Task, mask: Mach.ExceptionMask) throws -> [Mach.ExceptionPort]
Gets the exception ports for the task that catch the exception types specified by the mask.
static func exceptionPorts(forThread thread: Mach.Thread, mask: Mach.ExceptionMask) throws -> [Mach.ExceptionPort]
Gets the exception ports for the thread that catch the exception types specified by the mask.
let behavior: Mach.ExceptionBehavior
The behavior of the exception.
let threadStateFlavor: Mach.ThreadStateFlavor
The flavor of the thread state to send with exception messages.
func raise(_ type: Mach.ExceptionType, code: Int32, subcode: Int32, inThread thread: Mach.Thread = Mach.Thread.current, inTask task: Mach.Task = Mach.Task.current, wasMaybePACFail: Bool = false) throws
Raise an exception.