Different states of an iOS app

Different states of an iOS app:
  1. Not Running 
  2. Inactive
  3. active
  4. Background
  5. Suspended
1. Not Running

App is usually in this state when it is not launched yet or was running but was terminated by the system 

2. Inactive

App is running in the foreground but is currently not receiving any user events (it may be executing other code though), App usually enter into this state only briefly as it transitions into different state.

3. Active

App is in the Foreground and receiving user events. This is normal mode for foreground apps.

4. Background

App is in the background and executing code. Most app enters into this state briefly on their way to being suspended. However the app that request the extra execution time may remain in this state for a period of time.

5. Suspended

App is in the background but not executing code. The system moves apps to this state automatically and does not notify them before doing so, while suspended app remains in memory but does not execute any code

When a low memory condition occurs, the system may purge suspended apps without notice to make more space for foreground app.

Apps must be prepared for termination to happen any time and should not wait to save user data to perform other critical tasks. Suspended apps receives no notification when they are terminated.


if the app is currently running in the background and not suspended, the system calls  applicationWillTerminate: of its app delegate prior to termination. The system does not call this method when the device reboots.

1 comment:

  1. I am expecting more interesting topics from you. And this was nice content and definitely it will be useful for many people.
    iOS App Development Company
    Android App Development Company

    ReplyDelete