Type Method

runningApplicationWithProcessIdentifier:

Returns the running application with the given process identifier, or nil if no application has that pid.

Declaration

+ (instancetype)runningApplicationWithProcessIdentifier:(pid_t)pid;

Parameters

pid

The process identifier.

Return Value

An instance of NSRunningApplication for the specified pid, or nil if the application has no process identifier.

Discussion

Applications that do not have PIDs cannot be returned from this method.

See Also

Getting Running Application Instances

+ runningApplicationsWithBundleIdentifier:

Returns an array of currently running applications with the specified bundle identifier.

currentApplication

Returns an NSRunningApplication representing this application.