Instance Method

applicationWillTerminate:

Sent by the default notification center immediately before the application terminates.

Declaration

- (void)applicationWillTerminate:(NSNotification *)notification;

Parameters

aNotification

A notification named NSApplicationWillTerminateNotification. Calling the object method of this notification returns the NSApplication object itself.

Discussion

Your delegate can use this method to perform any final cleanup before the application terminates.

See Also

Terminating Applications

- applicationShouldTerminate:

Sent to notify the delegate that the application is about to terminate.

- applicationShouldTerminateAfterLastWindowClosed:

Invoked when the user closes the last window the application has open.

NSApplicationTerminateReply

Constants used by the delegate method applicationShouldTerminate: to determine whether an app should terminate.