{infiniteZest}
// Articles. Tutorials. Utilities.
Home  |   Search  |   Login  
Categories Skip Navigation Links
New / All
AJAX
Apple
ASP.NET
.NET
Git
Google / Android
Python / IronPython
Miscellaneous
SQL Server
Summary of various tools installed with iPhone SDK
Summary
This article gives a quick overview of the development tools installed with iPhone SDK. These tools include Xcode, Interface Builder, Instruments, and iPhone Simulator. Dash Code, which is used to build web applications for iPhone is also introduced. GDB, the open source debugger, is discussed as well.
 
Table of Contents

The Tools

Figure 1. The relationship between Xcode, GDB, Interface Builder, Instruments, and iPhone Simulator. These are the main tools for developing NATIVE iPhone applications. Dashcode is used for developing WEB applications.

Xcode

Figure 2. Xcode with Metronome project open. This is the central tool in the development toolset for iPhone, iPod Touch, and Mac OS X applications. All the project related files can be seen in the left navigator.

GDB (GNU Debugger)

Figure 3. The debugging functionality from Xcode, via a GUI window. This window is probably most helpful during most of the debugging. You can see the callstack, variable information, and source in the same window.

Figure 4. The debugging functionality from the GDB console. This window provides all the raw power of GDB. A large set of commands can be used to find out information about variables/objects, breakpoints, call stack, etc.

Interface Builder

Figure 5. The Interface Builder is shown with the Document Window, the View, the Attribute Inspector, and the Library (or the Toolbox). Here the user interface is a Table View, a commonly used view.

Instruments

Figure 6. Looking at the Object allocation and Leaks from Instruments.

Dashcode

Figure 7. Developing web applications for iPhone using Dashcode. You can see the standard web file extensions (.html, .css, and .js for JavaScript)

iPhone Simulator

Figure 8. A utility web application with Dashcode - shown in the iPhone Simulator. This does not require the iPhone SDK.

Figure 9. An application built from Xcode running inside iPhone Simulator. This application is native to iPhone OS and is built with iPhone SDK. This is NOT run inside the Safari web browser (though Internet functionality can be added to native iPhone applications)

 
Article Series
Previous Article:
Test Your Knowledge: Starting with Xcode for iPhone development
This article is part of the Series:
Article Series: Getting started with iPhone development
Next Article:
Test Your Knowledge: Summary of various tools installed with iPhone SDK

The Tools

If you are used to developing with Visual Studio or Eclipse, all the necessary features / dev-tools are available from one user interface. With Visual Studio, more features are available with higher editions.

With Mac / iPhone development, the situation is slightly different. The tools are a little bit spread out and come with different names. However, they all work collectively to build the application. If you were to refer them by one brand name, they are called Xcode Tools. And, all these applications / development tools are installed when you install the iPhone SDK.

You would need to work with at least the following two tools to develop applications for iPhone:

  • Xcode - for coding
  • Interface Builder - for developing user interfaces

In addition to the above two, you would use a tool called Instruments to do the performance analysis on the application you developed.

Then there is the Dashcode, which can be used for developing web applications on iPhone. And finally, there is the iPhone Simulator which assists a great deal in developing applications for iPhone. You can test your applications more conveniently with the iPhone Simulator, before testing them with the iPhone device.

Figure 1. The relationship between Xcode, GDB, Interface Builder, Instruments, and iPhone Simulator. These are the main tools for developing NATIVE iPhone applications. Dashcode is used for developing WEB applications.

Figure 1. The relationship between Xcode, GDB, Interface Builder, Instruments, and iPhone Simulator. These are the main tools for developing NATIVE iPhone applications. Dashcode is used for developing WEB applications.

Xcode

The central tool in Xcode toolset is Xcode. This tool provides a way to:

  • Create and Manage Projects
  • Write code via Source Code Editor
  • Compile and Run applications
  • Debug applications (GDB is used under the covers)
  • Be the front-end for Source Code Management (SCM) system
  • Launch Interface Builder for creating user interface
  • Launch Instruments for the performance analysis

Figure 2. Xcode with Metronome project open. This is the central tool in the development toolset for iPhone, iPod Touch, and Mac OS X applications. All the project related files can be seen in the left navigator.

Figure 2. Xcode with Metronome project open. This is the central tool in the development toolset for iPhone, iPod Touch, and Mac OS X applications. All the project related files can be seen in the left navigator.

As you can see, Xcode lets you manage and develop the files related to the iPhone project. You have the usual source code files, with extensions .h (header) and .m (implementation). You have the files with extensions .framework and .dylib, which are the frameworks and dynamic libraries. Then you have the .xib and .nib files, which represent the user interfaces of the applications. These files are created and updated with Interface Builder.

From the Groups & Files section, you can see the source control (SCM), the project symbols that provide information about variables during debugging, what executables are constructed out of the source, etc.

GDB (GNU Debugger)

GDB is the open source debugger that supports a whole bunch of languages, including C, C++, Objective-C, and Java. Xcode provides the GDB capabilities from a graphical user interface or from a raw command line console where GDB commands can be executed.

Figure 3. The debugging functionality from Xcode, via a GUI window. This window is probably most helpful during most of the debugging. You can see the callstack, variable information, and source in the same window.

Figure 3. The debugging functionality from Xcode, via a GUI window. This window is probably most helpful during most of the debugging. You can see the callstack, variable information, and source in the same window.

Figure 4. The debugging functionality from the GDB console. This window provides all the raw power of GDB. A large set of commands can be used to find out information about variables/objects, breakpoints, call stack, etc.

Figure 4. The debugging functionality from the GDB console. This window provides all the raw power of GDB. A large set of commands can be used to find out information about variables/objects, breakpoints, call stack, etc.

Interface Builder

The Interface Builder is used to graphically develop (“draw”) the user interface of an application. These files have the extension .xib (which roughly stands for XML - Interface Builder). These are the textual XML files. These files become .nib files (binary - roughly stands for NextStep - Interface Builder) after compilation and are included in the .app file of the application.

You can open these user interface files in the Interface Builder by double-clicking them in the Xcode project window. New user interface files can be created from the File-New menu of the Interface Builder.

Figure 5. The Interface Builder is shown with the Document Window, the View, the Attribute Inspector, and the Library (or the Toolbox). Here the user interface is a Table View, a commonly used view.

Figure 5. The Interface Builder is shown with the Document Window, the View, the Attribute Inspector, and the Library (or the Toolbox). Here the user interface is a Table View, a commonly used view.

Instruments

You can perform memory analysis, leak detection, and other performance analysis tasks with a tool called Instruments. This can be run directly from Xcode (from Run - Start with Performance Tool menu item).

Figure 6. Looking at the Object allocation and Leaks from Instruments.

Figure 6. Looking at the Object allocation and Leaks from Instruments.

Instruments tool is based on the DTrace toolkit that is part of the OpenSolaris. The “D” in DTrace stands for Dynamic, meaning DTrace provides the Dynamic Tracing functionality.

Dashcode

Dashcode is used to develop widgets for the dashboard on Mac OS X. It can also be used to develop web applications for iPhone. Meaning, these applications run inside Safari on iPhone. This is different from developing applications with Xcode, where applications are developed for native iPhone operating system. With Dashcode, you would use the standard web technologies like HTML, CSS, and JavaScript to develop these web applications for iPhone.

Figure 7. Developing web applications for iPhone using Dashcode. You can see the standard web file extensions (.html, .css, and .js for JavaScript)

Figure 7. Developing web applications for iPhone using Dashcode. You can see the standard web file extensions (.html, .css, and .js for JavaScript)

iPhone Simulator

You can test the applications you developed for iPhone right on the Mac, before transferring them over to an actual iPhone device. You can use the iPhone Simulator to test the applications developed for native iPhone OS, using Xcode. You can also use iPhone Simulator to test the web applications developed using Dashcode.

Figure 8. A utility web application with Dashcode - shown in the iPhone Simulator. This does not require the iPhone SDK.

Figure 8. A utility web application with Dashcode - shown in the iPhone Simulator. This does not require the iPhone SDK.

Figure 9. An application built from Xcode running inside iPhone Simulator. This application is native to iPhone OS and is built with iPhone SDK. This is NOT run inside the Safari web browser (though Internet functionality can be added to native iPhone applications)

Figure 9. An application built from Xcode running inside iPhone Simulator. This application is native to iPhone OS and is built with iPhone SDK. This is NOT run inside the Safari web browser (though Internet functionality can be added to native iPhone applications)

The above program is the Metronome sample, which uses the iPhone SDK. The graphics functionality comes from the CoreGraphics/QuartzCore frameworks and the audio functionality comes from the AudioToolbox framework.

Take a Quick Quiz on this Article

1. Which of the following is NOT true about Xcode?



: There is a separate tool called Interface Builder
Question 1 of 5
Article Series
Previous Article:
Test Your Knowledge: Starting with Xcode for iPhone development
This article is part of the Series:
Article Series: Getting started with iPhone development
Next Article:
Test Your Knowledge: Summary of various tools installed with iPhone SDK
Bookmark and Share This

More Articles With Similar Tags
This is a test on the article that gives a quick overview of the development tools installed with iPhone SDK. These tools include Xcode, Interface Builder, Instruments, and iPhone Simulator. In the article, Dash Code, which is used to build web applications for iPhone is also introduced. GDB, the open source debugger, is discussed there as well.
icon-xcode-groups-files.jpg
This article discusses various parts of the Project window inside an Xcode project. It also gives a quick overview of the Groups and Files navigation window. The Run menu, the default toolbar, and the built-in source editor are also discussed.
This is a test on the article that discusses various parts of the Project window inside an Xcode project. It also gives a quick overview of the Groups and Files navigation window. The Run menu, the default toolbar, and the built-in source editor are also discussed.
icon-xcode-interface-builder-connection-panel.jpg
This article explains the user interface files of an iPhone application. Explains the contents of the .xib files, which store the user interface. Goes through the various windows (Document Window, User Interface Window, Inspector Window, Library Window, Connections Panel) of the Interface Builder. The example used is a simple navigation-based iPhone application.
This is a test on the article that explains the user interface files of an iPhone application. It explains the contents of the .xib files, which store the user interface. Goes through the various windows (Document Window, User Interface Window, Inspector Window, Library Window, Connections Panel) of the Interface Builder. The example used is a simple navigation-based iPhone application.
About  Contact  Privacy Policy  Site Map