Returns the shared instance representing a target application specified by its process identifier.
- macOS 10.5+
The BSD process ID of a OSA-compliant application. Often you can get the process ID of a process using the
An instance of an
SBApplication subclass that represents the target application whose process identifier is
nil if no such application can be found or if the application does not have a scripting interface.
You should avoid using this method unless you know nothing about a target application but its process ID. In most cases, it is better to use
application, which will dynamically locate the application's path at runtime, or
application, which is not dependent on the target application being open at the time the method is called.