21⟩ Described iPhone app?
An iPhone app is a program that runs on our iPhone/iPod Touch. It enables us to ccomplish a certain task. They could be utility apps, games, enterprise apps, entertainment apps, apps to access our bank account etc.
“IPhone Developer Frequently Asked Questions in various IPhone Developer job Interviews by interviewer. The set of questions here ensures that you offer a perfect answer posed to you. So get preparation for your new job hunting”
An iPhone app is a program that runs on our iPhone/iPod Touch. It enables us to ccomplish a certain task. They could be utility apps, games, enterprise apps, entertainment apps, apps to access our bank account etc.
iPhone SDK is available with tools and interfaces needed for developing, installing and running custom native applications. Native applications are built using the iPhone OS's system frameworks and Objective-C language and run directly on iPhone OS. Native applications are installed physically on a device and can run in presence or absence of network connection.
iPhone reference library is a set of reference documents for iPhone OS. It can be downloaded by subscribing to the iPhone OS Library doc set. Select Help>Documentation from X code, and click the subscribe button next to the iPhone OS Library doc set, which appears in the left column.
Shallow copy is also known as address copy. In this process you only copy address not actual data while in deep copy you copy data.
Suppose there are two objects A and B. A is pointing to a different array while B is pointing to different array. Now what I will do is following to do shallow copy. Char *A = {'a','b','c'}; Char *B = {'x','y','z'}; B = A; Now B is pointing is at same location where A pointer is pointing.Both A and B in this case sharing same data. if change is made both will get altered value of data.Advantage is that coping process is very fast and is independent of size of array.
while in deep copy data is also copied. This process is slow but Both A and B have their own copies and changes made to any copy, other will copy will not be affected.
A struct is a special C data type that encapsulates other pieces of data into a single cohesive unit. Like an object, but built into C.
iPhone responds to motion using a built-in accelerometer.
The accelerometer detects the movement and changes the display accordingly, at the time of rotating iPhone from portrait to landscape.
Before the launch of an app, it is said to be in not running state.
When an app is launched, it moves to the active or background state, after transitioning briefly through the inactive state.
On state transitions can be responded to state changes in an appropriate way by calling corresponding methods on app's delegate object.
For example:
application Did Become Active method can be used to prepare to run as the foreground app.
application Did Enter Background method can be used to execute some code when app is running in the background and may be suspended at any time.
application Will Enter Foreground method can be used to execute some code when your app is moving out of the background application Will Terminate method is called when your app is being terminated.
An app is said to be in 'not running' state when:
it is not launched.
it gets terminated by the system during running.
The UIKit framework is used to develop application's user interface for iOS. UIKit framework provides event handling, drawing model, windows, views, and controls specifically designed for a touch screen interface.
UIKit classes should be used only from an application's main thread. Note: The derived classes of UIResponder and the classes which manipulate application's user interface should be used from application's main thread.
iOS development requires Intel-based Macintosh computer and iOS SDK.
During app launching, the system creates a main thread for the app and calls the app's main function on that main thread. The Xcode project's default main function hands over control to the UIKit framework, which takes care of initializing the app before it is run.
An app can get into InActive state when the user locks the screen or the system prompts the user to respond to some event e.g. SMS message, incoming call etc.
An app will be in InActive state if it is running in the foreground but is currently not receiving events. An app stays in InActive state only briefly as it transitions to a different state.
An app is said to be in active state when it is running in foreground and is receiving events.
In case system is running low on memory, the system may purge suspended apps without notice.
An app enters background state briefly on its way to being suspended.
Background state.
An app is said to be in suspended state when it is still in memory but is not executing any code.