Streamezzo S.A. - All rights reserved
Copyright 2001-2010
How to create an application for Android devices
Streamezzo Solution allows creating applications for any platform.
This tutorial details how to create an application for Android devices using Streamezzo Workbench Developer, i.e. the provided client package creation wizard and the comparable Ant task.
Introduction
A Client Package is an installer that is specifically designed to fit in for a given target handset.
For an Android device one will obtain a .apk file.
Client package creation is a 3-step process:
- Configuration
- Packaging
- Signing
Prerequisites
One must install Streamezzo
Android
Mobile Package Creator (AMPC) application in order to support
the creation fo client packages for Android devices in Streamezzo
Workbench Developer.
See Android Mobile Package Creator Tutorial for its
specific pre-requisites (especially note the default JRE must be in
version 1.6 or higher).
Application configuration can be accessed from the Service > Service Settings > Application configuration tab in Workbench Developer.
In order to customize an application one will need to specify:
- Standard settings, i.e. application name, application icon (see requirements below)...
- (optional) Advanced settings, i.e. screen orientation changes handling

Icon
The Android application launcher icon must be a tansparent either 36x36 or 48x48 or 72x72 PNG image. The Icon Design Guidelines can be found [here].
Signing
Signing an application is a necessary step for commercial distribution, and eventually for testing purpose.
On Android devices, the signing procedure for testing purpose requires a pair of private and public keys (auto generated).
On Android devices, if (and only if) one wants to publish via the Android Market then one will have to create an Android Developer Profile (25 USD registration fee). The cryptographic keys must have at least a 25 years validity period.
Public/Private key pair generation
The key generation follows the same process as a Java MIDlet key
generation. One will need to use the keytool command. For
Android signing one will need to create a key with a huge
validity period. It is because all the updates of the application must
be signed with the same key.
One will have to execute the following command line:
- keytool -genkey -v -keystore my-release-key.keystore -alias alias_name -keyalg RSA -validity 10000
If one wants to publish the application on the Android Market, one will need to create an Android Developer Profile (25USD). Here is a [link] to a complete guide for Android publishing.
Packaging
Wizard
Application packaging can be accessed from the Service > Create Client Packages menu option in Workbench Developer.
In order to package an application one will need to specify:
- Targeted device(s), i.e. select all devices the application is supposed to support
- Application configurations, i.e. all defined configurations (as defined in the Prequisites section above) can be set / updated here
- Rich Media Server information, i.e. required parameters to access Streamezzo Rich Media Server instance if any (i.e. if the application contains server-side scenes)
- Output, i.e. output folder and pattern (this last parameter is mandatory in case multiple devices are selected for packaging, as each application installer will need to be dumped in a separated and identified folder, inside the output folder)

Once the "Finish" button is pressed, all requested client packages will be generated for each selected device.
If specified in the configuration, the application will be automatically signed.
The progression of the client packages creation can be followed in the Client packages creation view.
Once a client package has been created, its output folder can also be accessed from here.
Ant task
Some operations as accomplished above with the wizard can be performed relying on an Ant task, which is usually comfortable to reiterate a client package creation in a given configuration (i.e. selected devices, configuration, output...) in a 1-click operation.
In order to do this one can follow those steps:
- Create an Ant build file
- Open it in the Workbench Developer editor
- Right-click in the editor area and select Wizards > Create client package target
- Follow the same wizard steps as detailed above; once the "Finish" button is pressed, the Ant build file will be automatically filled accordingly (instead of really creating the client package(s))
The obtained Ant task looks like this:
<?xml version="1.0" encoding="UTF-8"?>
The Ant build file can then be dumped in the Ant view and executed from here.
The progression of the running Ant task can be followed as successive logs in the Console, ending with message "BUILD SUCCESSFUL" in case it succeeded.
Distribution
Once properly packaged and signed, a Java application can be distributed OTA by any applicable mean, i.e. FTP, Provisioning Server... or via the Android Market (commercial distribution).