Packaging a Hybrid Application

The Tizen platform allows you to create hybrid application packages, which combine a Web UI application and 1 or more native service or widget applications.

hybridpackage_overview

 

Creating a Project for a Hybrid Package

To create the projects for a hybrid package:

  • Create a Web UI project:

    1. In the IDE, select File > New > Tizen Web Project.

    2. Select a basic application template, enter the project name, check the version, and click Finish.

      create_web_project

  • Create a native service or widget project:

    1. In the IDE, select File > New > Tizen Native Project.

    2. Select the service or widget application template, enter the project name, check the version, and click Finish.

      create_native_project

  • The created projects are shown in the Project Explorer view.

    project_explore_view

Defining Project Settings for Hybrid Packaging

To create a hybrid package, establish a project reference between the Web and native projects:

  1. In the Web UI project context menu, select Properties > Tizen SDK > Package > Multi.
  2. Select the check box for the service or widget application to be included in the hybrid package, and click OK.

    properties

    In the Project Explorer view, the native project shows that it is referenced with the Web UI project.

Building a Hybrid Package

To build a hybrid package:

  1. In the Web UI project context menu, select Build Package.

  2. The IDE generates a WGT package that contains the Web and native applications.

    The generated WGT file has the following content hierarchy:

Checking the Native Manifest File in the WGT File

The hybrid package contains a config.xml file (from the Web project) and a tizen-manifest.xml file (from the native project).

During packaging, the package and appid values of the tizen-manifest.xml file are changed based on the config.xml file.

  • config.xml (Web UI application)

    <?xml version="1.0" encoding="UTF-8"?>
    <widget xmlns:tizen="http://tizen.org/ns/widgets" xmlns=http://www.w3.org/ns/widgets
            id="http://yourdomain/WebBasicApplication" version="1.0.0" viewmodes="maximized">
       <tizen:application id="Mz5h6LQ0GH.WebBasicApplication" package="Mz5h6LQ0GH"
                          required_version="2.3.1"/>
        …
       <tizen:profile name="wearable"/>
    </widget>
    
  • tizen-manifest.xml in the WGT file (package and appid values have been replaced)

    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <manifest xmlns="http://tizen.org/ns/packages" api-version="2.3.1" package="Mz5h6LQ0GH"
              version="1.0.0">
       <profile name="wearable"/>
       <service-application appid="Mz5h6LQ0GH.nativeserviceapplication"
                            exec="nativeserviceapplication"
                            multiple="false" nodisplay="true" taskmanage="false" type="capp">
        …
       </service-application>
    </manifest>
    
List
SDK Version Since: 
2.4.0