Start from the device boot :~

  • When the user opens the iPhone, no other App is running except the operating system App. When the user clicks the App icon, SpringBoard will launch the App.

    • SpringBoardIs a system standard application for managing the iPhone’s home screen (home screen). It also includes issues with managing window services, starting applications, and setting up some devices.
  • When SpringBoard opens the App’s Launch Screen, the system loads your App and the necessary associated libraries into memory. And finally your App is going to start executing and the application delegate is going to get notified.

    • AppDelegateIs a delegate object. Inherited fromUIResponderClass, and implementationUIApplicationDelegateEntrust agreement
  • The entry point for an iOS App is UIApplicationDelegate. This is a protocol, and you need to implement it in your App, so you can get the program started, go to background/foreground, etc.

  • The UIResponder class enables an AppDelegate to respond to user actions. And UIApplicationDelegate can make the AppDelegate an application delegate object to manage and respond to the application lifecycle.

Execution status of Apps :-

  • Not running (Not Running state) : The app has not been run or terminated by the system
  • Inactive state (Inactive state) : The app is about to enter the foreground, but no event is received
  • Active state (Active state) : The app enters the foreground and can handle events
  • Background Status (Background state) : In this state, if there is code being executed, then the execution continues; If no code is executed or executed, then the app is suspended.
  • Suspended state (Suspended state) : The app dies in the background (i.e. in memory) but does not execute code, and the system terminates the app if it does not have enough memory