There are a number of important steps you should follow to develop an app.
- Create the app
- You can use the Momentics IDE to set up the project and required files or create one manually using the command line.
- Add libraries
After you create the project, you can decide on the libraries to add. You can add libraries to your project any time during the development process but it makes it easier to code if you know ahead of time what to include in your project. Several libraries come installed with the BlackBerry 10 Native SDK. If you require a library not available with the Native SDK, there are a vast number of open source libraries that are available that you can use. You may even have libraries of your own that you can use or create. If your libraries use POSIX-standard C/C++ calls and compile using the GNU C/C++ compiler, they likely can be ported for use with the BlackBerry 10 OS.
- Add resources and permissions to the app
You must create or edit an existing BAR application descriptor file. You add assets (icons, images, additional libraries) and set up permissions for your app using the application descriptor file. In addition, you can configure the name of your app, title for the app, etc. using the file.
- Write the code
- You should have a good understanding of the fundamentals before you start
but this is where the real work (and fun!) begins. A basic application
contains code that:
- initializes resources, such as data/graphics
- controls a main loop that handles events, modifies the application state, and renders graphics
- cleans up resources upon exiting
- Compile the app
While you are coding, you will need to compile your app. Compiling your code may require that you specify additional options or parameters. You can specify them in managed projects using the IDE or modify a makefile in a Makefile project. Make sure that you test any libraries that you add to ensure they compile with your app.
- Package and deploy the app
Once your app compiles, you can package the app and deploy it. During the packaging process, your compiled app is packaged into a BAR file. The BAR file is deployed on a device or simulator. This process can be completed using a launch configuration from the IDE or using a series of steps from the command line.
- Test and debug the app
After you deploy your app, you can start testing! During the testing phase, you may find issues with your code that you need to resolve, but eventually, you will have an app that's ready to deploy. As you fix your code, you need to repackage and deploy your code. When your apps become larger, the packaging and deployment process might be cumbersome and time-consuming. You can perform incremental updates to your deployed app to help reduce the time. After you are satisfied with your app, you can deploy using BlackBerry World.
Last modified: 2013-12-21