0% found this document useful (0 votes)
5 views

Usman2014 - A Model Driven Approach To Generate Monile App For Multiple Platform

Uploaded by

SimoneTinelli
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Usman2014 - A Model Driven Approach To Generate Monile App For Multiple Platform

Uploaded by

SimoneTinelli
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

2014 21st Asia-Pacific Software Engineering Conference

A Model-driven Approach to Generate Mobile Applications for Multiple Platforms

Muhammad Usman Muhammad Zohaib Iqbal1,2, Muhammad Uzair Khan1


Software Quality Engineering & Testing Laboratory 1
Software Quality Engineering & Testing Laboratory
National University of Computer and Emerging Sciences National University of Computer and Emerging Sciences
Islamabad, Pakistan Islamabad, Pakistan
[email protected] 2
SnT Centre, University of Luxembourg, Luxembourg
{zohaib.iqbal, uzair.khan}@nu.edu.pk

Abstract—Mobile application development has emerged as one support multiple mobile platforms [4]. In the current
of the most focused areas in software industry due to industrial practice, a number of versions of applications are
exponential growth of mobile users and applications. The focus developed and maintained to support multiple platforms; for
of the current mobile industry is on direct implementation, example Android application cannot run on Windows Phone.
rather than analysis and design. Model-driven engineering With the growing number of mobile users of all platforms,
practices are ignored, which results in low reusability and lack current practices are not sufficient. The developer has to
of portability along with other challenges. In addition, mobile perform redundant effort to develop the same mobile
applications also have to support multiple platforms, as an application for different platforms.
application written for one platform (e.g., Android) cannot run
Model-driven software engineering is a widely accepted
on another platform (e.g., Windows Phone). Each of the
methodology for developing software systems where models
platforms in turn suffers from fragmentation. This results in
multiple versions of an application that need to be
are considered as the key artifact [5]. Unified modeling
simultaneously maintained. This is a huge burden on the language (UML) [6], is commonly used for developing
development team, both in terms of cost and effort, due to software systems and has been successfully applied in
various platforms that an application supports. This paper different domains [7-9]. It consists of a standardized set of
proposes a model-driven approach to generate mobile notations and semantic rules that provide ways to model both
applications for multiple platforms. We carefully identify a structural and behavioral properties of the system. UML
subset of UML and propose a modeling methodology for this models can prove more beneficial for mobile application
purpose. We use real use-cases for requirement gathering, modeling because it allows platform independent modeling
class diagram for structural modeling, while state machine are and transformation to different mobile platforms.
used for behavioral modeling. We focus on modeling business MDE is not new for mobile application development
logic layer for the mobile application. We also propose a UML [10]. Although there are numerous domain specific
profile for modeling mobile domain specific concepts. Our languages (DSLs) available for mobile application
approach uses Action Language for Foundational Subset of development [11, 12] but no modeling language exists to
UML (ALF) to specify actions in the state machines. Our model mobile application, so we use UML for this purpose.
approach allows the modeler to automatically generate An important constraint in mobile applications is the short
business logic code for multiple platforms. The approach is time to market and quick delivery because of high market
supported by an automated tool MAG (Mobile Application
competition between various vendors [3]. The large number
Generator). We apply our model-driven approach on an
of diagrams in UML is a problem for mobile application
industrial case study ‘Scramble’ app developed by ‘NextIn’ to
demonstrate its viability.
modeling. It is common to identify a subset of UML for
modeling in particular domain [7, 8]. Therefore, we selected
Keywords-mobile software engineering; UML; use-case a minimal subset of UML for the purpose of modeling
diagram; class diagram; state machine; automated application mobile applications.
generation; native application A key requirement of model-driven approach for mobile
application development is that the modeling language
I. INTRODUCTION allows modeling of mobile domain specific concepts (for
Mobile application development has recently emerged as example, bluetooth, WIFI, contact, message). UML and its
one of the most focused areas in software industry [1]. standard extension mechanism (i.e., UML profiles) have
Exponential growth of mobile users, extensive use of mobile been used widely for modeling domain specific applications
devices and the variation in mobile platforms has largely [13]. The existing UML notations are not adequate to model
influenced the mobile application development [2]. Currently mobile application. We use the standard UML extension
there are around 2.5 million mobile applications available for mechanism to develop a profile for the modeling domain
various platforms. specific concepts related to mobile application development.
The increase in mobile application development has For any model-driven approach to be practically applicable,
attracted attention in software engineering [1, 3, 4], but the providing a set of notations is not sufficient. A detailed
current software engineering practices do not scale well to guideline on how to apply the notations in practice is also
the growing needs of mobile industry. A key problem faced essential [14]. Therefore we also provide guidelines on how
by developers is the requirement of mobile applications to to model mobile applications using UML and our profile.

1530-1362/14 $31.00 © 2014 IEEE 118


111
DOI 10.1109/APSEC.2014.26
In this paper, we propose a model-driven approach for organization is developing a variety of mobile applications
automated generation of mobile applications for various ranging from game applications to general-purpose utility
mobile platforms. We carefully identify a subset of UML applications. NextIn initially targeted Amazon’s Kindle fire
that fits the need of mobile domain. The subset includes devices through Amazon’s app market. They have since
UML use-case diagram, class diagram, and the state machine expanded to support other devices and platforms such as iOS
diagram. We use real use-cases for requirements gathering, and Apple app store, Google play for Android applications
class diagram for structural modeling, and state machine for and Nook tablets. Some of their well-known applications are
behavioral modeling of the mobile application. For mobile scramble, flow dots, and slideagram.
domain specific modeling, we propose a mobile UML The mobile application that we use to demonstrate our
profile. For executable code generation, we use ALF [15] as model-driven approach is scramble [19]. It is developed for
an action language, to write various actions in state Android and published in Amazon store by NextIn. Scramble
machines. Our methodology allows the software designers to is an English words’ learning game that helps to improve
model the application in a platform independent way, where vocabulary. Figure 1 shows that the scramble board that
the focus is on the business logic of the application. To consists of a 5x5 squares containing a set of 25 characters
generate mobile application automatically, we develop a tool (one at each position). The words are scrambled, so a
named Mobile Application Generator (MAG) that takes the particular word can be found in an irregular pattern by
developed UML models as input and generates application moving in 8 different directions. The game contains a timer
for the specified target mobile platforms. Our approach to allow word’s creation in a specific time. The game also
implements controller design pattern [16] on top of the shows hints for different words during the play.
generated code. The controller pattern allows the integration
of the business logic with the user interface.
Note that the proposed model-driven approach focuses on
modeling and generation of business logic of mobile
applications. The graphical user interface (GUI) needs to be
developed separately for each mobile platform (e.g., by using
a drag-drop utility). The existing GUI development tools are
well-suited for this purpose as they already hide the
underlying GUI code during development. In most of the
cases, the GUI needs to be tailored according to the screen
sizes and resolutions of the mobile devices.
The rest of the paper is organized as follows: Section II
highlights the practical aspects of mobile application
development. Section III defines our proposed model-driven
approach for mobile application development. Section IV
provides information about application generation process.
Section V describes the developed prototype tool. Section VI
evaluates our methodology by automatically generating code
for an industrial case study. Section VII compares the
generated application with current industry trends. Section
VIII presents the related work and Section IX finally Figure. 1. Scramble mobile application game screen.
concludes the paper.
NextIn intends to develop scramble application for other
II. PRACTICAL ASPECTS platforms including Microsoft Windows Phone. The current
In this section, we describe the current problems in version of the application is implemented for Android and
mobile application development industry. We briefly therefore the application is not available on Windows Phone.
introduce our industrial partner and the case study that we The company has to build the same application for Windows
use to demonstrate our proposed model-driven approach. Phone from scratch which is a huge overhead in terms of
There are over one million Android applications effort, time and money. Consequently, the company is
currently registered in Google play [17]. This reflects a huge looking for ways to reduce the development and
mobile market, but it also highlights the problem that mobile maintenance efforts.
users using different operating systems cannot use these We propose a model-driven approach to solve this
applications. To run Android application on different mobile problem. We demonstrate our approach by designing a
platforms, a redundant effort is required to build the same mobile application using a set of UML models and mobile
application from scratch, resulting in loss of time and money UML profile. The developed models are used to generate
[3]. This problem is not specific to Android operating mobile applications for different mobile platforms (including
system, but in general, an application written in one platform the required Microsoft Windows Phone platform). This
cannot be used on other platforms. shows the applicability of our model-driven approach to
Our industrial partner is a mobile application generate mobile applications automatically.
development organization in Pakistan, NextIn [18]. The

112
119
III. MODEL-DRIVEN APPROACH B. Mobile Application Requirements Modeling
In this section, we present our proposed model-driven The first step in application development is to develop
approach for mobile application development. We first use-cases. Use-cases are widely accepted as a useful way of
identify the set of notations required to model mobile gathering requirements. Due to the nature of mobile
applications. We extend the standard UML notations by applications, we suggest to use real use-cases [8] (i.e., use-
proposing a UML profile for mobile domain specific cases with technological details). The real use-cases define
concepts modeling. the requirements of the mobile application with the help of
Our approach consists of three major phases: application screens (i.e., user interfaces) and the UML use-
requirements modeling, structural modeling and behavioral case diagram. Application screens are helpful for gathering
modeling. Keeping the requirements of mobile application requirements in mobile application development. By using
development in view (e.g., short development cycles); we application screens, we can define various business
carefully identify a minimal subset of UML notations for scenarios. These screens can be used for further elaborating
mobile application modeling, consisting of: (i) use-case the requirements.
diagram, (ii) class diagram, and (iii) state machine diagram. We use the standard UML use-case diagram. The use
First we describe our proposed mobile UML profile used for cases can be written using any format, such as the one
mobile application modeling and then we present our proposed by Larman [8]. Figure 3 shows an excerpt of the
proposed model-driven approach for mobile application. UML use-case diagram for the scramble mobile application.
It shows three use-cases. Mobile application runs in highly
A. Mobile UML Profile interrupt-oriented environment where a call or message or
Mobile domain specific concepts (such as, bluetooth, any other notification can interrupt the running application at
WIFI, contact, message) cannot be adequately expressed in any time instance. In our approach, by default all the use-
the standard UML diagrams. We define a UML profile for cases are interruptible, i.e., whenever there is an interrupt,
modeling mobile domain specific concepts. We applied the the application pauses. To specify uninterruptible scenarios,
profile definition methodology as suggested by Selic [20]. we provide a stereotype NonInterruptible in mobile UML
profile. It is used to mark uninterruptible use-cases in UML
use-case diagram as shown in Figure 3.

Figure. 2. An excerpt of mobile UML profile.


Figure. 3. UML use-case diagram for scramble game.
We first identify mobile domain specific concepts, their
relationships and constraints. Then we map the identified C. Mobile Application Structural Modeling
concepts to the UML meta-concepts on the basis of their After requirements modeling, the next step is the
semantics. In the end, we identify the attributes for the structural modeling of the mobile application. For this
concepts. Figure 2 shows the excerpt of the profile diagram purpose, we use UML class diagram to capture structural
of proposed mobile UML profile. The various concepts of details. The mobile application class diagram defines the
the profile are presented in Table I as stereotypes. business concepts, mobile domain specific concepts, their
characteristics, and their relationships with one another. The
TABLE I. MOBILE UML PROFILE STEREOTYPES DESCRIPTION. identification of the classes, their properties, their
Stereotype Definition relationships, and mobile specific concepts for the
Persistence Allows to store / retrieve data application is helped by application screens, the UML use-
Content- Integrates different content types support in the case diagram, and the extension section in expanded use-case
Manager application
Notification- Allow to handle and show phone notification via light, format [8]. For example, scramble application contains a
Handler sound or vibration board to play the game, and a player who plays the game, so
Bluetooth Include bluetooth functionalities in the application Board and Player are modeled as classes in class diagram.
Figure 4 shows an excerpt of UML class diagram for
scramble mobile application. The designer annotates the

113
120
mobile domain specific concepts using stereotypes defined in to model the application in an independent way. The
mobile UML profile, in the class diagram. Persistence application generator will automatically generate the target
stereotype is used to model DBHandler class. During application according to the selected platforms.
application generation, Persistence stereotype transforms to
the mobile platform specific API class.

Figure. 4. UML class diagram for scramble game.

Currently we are focusing on modeling the business logic Figure. 5. UML state machine diagram for Board class.
layer of the mobile application. The user interface (GUI)
code is generated automatically using GUI modeling tools IV. MOBILE APPLICATION GENERATION
(e.g., the one provided by Microsoft Visual Studio). Our We use the developed models to generate the code for the
approach requires a separation of business logic and GUI business logic layer of the application. The code generation
code. This is accomplished via the controller pattern [8, 16]. depends on the class and state machine diagrams. The
Figure 4 shows Frame and BLController. The Frame class process is divided into two parts, i.e., (i) structural code
represents the GUI components, whereas the BLController generation, and (ii) behavioral code generation. Both are
class represents the business logic controller. BLController explained in the following sub-sections.
class handles all the requests from the GUI.
A. Structural Code Generation
D. Mobile Application Behavioral Modeling
The developed UML class diagram is used to generate
After creation of class diagram the next step is behavioral the code for structural features of the mobile application. We
modeling of the mobile application. For this purpose, we use follow the well-known code generation principles for
UML state machine diagram to capture behavioral details. generating code from class diagram [21]. For example, for
For the classes in the class diagram that have a behavior, each modeled class in the class diagram, a class in the
state machines are developed. The class diagram classes specific programming language based on the mobile
whose properties change after a certain event or action in the platform is generated, such as, for Board class, Java Board
application screens can be considered as classes with stateful class is generated for Android platform, C# Board class is
behavior. Figure 5 shows the UML state machine diagram generated for Windows Phone platform, while Object C
for Board class. The application screen associated with the Board class is generated for iOS platform. The attributes in
Board class helps to identify states. For example, we identify the modeled class transforms into fields in the generated
a state New Word Created in response to the player action to class. Getter and setter methods for all the fields are also
create new word on the board application screen. Figure 5 generated automatically. The operations in the modeled class
contains four states for BoardSM. In mobile application state transform into methods in the generated class. The
machine, we mostly have simple states and call events but in navigation property in the association relationship provides
case of an interrupt, a signal event is generated by mobile the information about the link creation in the generated class.
operating system. We use mobile UML profile for modeling mobile domain
To generate executable code from state machine, we specific concepts, so the modeled classes in the class
select the standard action language for UML, ALF to specify diagram contain the stereotypes from the mobile UML
various actions [15]. ALF is pretty much similar to Java profile. We propose mappings of mobile UML profile
language. It is easy to use and understand. It more or less stereotypes to different mobile platforms specific API
presents all the behavior of the application. Figure 5 shows classes. For instance, Persistence stereotype correspond to
the actions in response to an event in each transition. In the android.content.ContentProvider class in Android API
Figure 5, the content written after backslash (/) is action. and Microsoft.Phone.Storage.ExternalStorage class in
In our proposed approach, the modeler does not need to Windows Phone API. During application generation, these
consider the underlying paradigm of target application mappings are used to generate code corresponding to the
development language while modeling. The modeler needs platform. The mappings of the mobile UML profile to the

114
121
Android and Windows Phone platforms are presented in Generator). It takes the UML models developed using our
Table II. Table II shows important stereotypes and their proposed model-driven approach and generates the business
mappings. logic layer of mobile applications for multiple platforms.
Current implementation of MAG only supports Android and
TABLE II. STEREOTYPES’ MAPPINGS Windows Phone mobile platforms, but can easily be
Stereotype Android Windows Phone extended to support other platforms.
Message android.telephony. Windows.Devices.Sms. Figure 7 shows the architecture of the tool. The
SmsManager SmsDevice developed tool consists of three main components: (i) Model
Application- android.app.Activity Microsoft.Phone.Controls.Phone Reader, (ii) Mappings Resolver, and (iii) Application
Activity Manager ApplicationPage
Background- android.app.Service Microsoft.Phone.Shell.
Generator.
Service PhoneApplicationService
Persistence android.content. Microsoft.Phone.
ContentProvider Storage.ExternalStorage
WIFI android.net.wifi.Wifi Windows.Devices.Wifi
Manager Direct.WifiDirectDevice

B. Behavioral Code Generation


The developed UML state machine(s) is used for the
generation of code for behavioral features of the mobile
application. The classes for all the state machines are already
created in the previous step with their properties, methods,
and relationships. For transforming UML state machines to
their equivalent code, we use the well-known state pattern
[16]. For state pattern, every state is transformed to a class.
Figure 6 shows the class hierarchy generated for the Board
state machine (shown in Figure 5) using state pattern.

Figure. 7. Mobile Application Generator (MAG) architecture.

A. Model Reader
The model reader is the first component in the MAG tool.
The input to this component is UML models (.uml file
extension) which consists of a class, state machine and UML
profile diagrams. This component is further divided into
three internal sub-components: (i) class diagram reader, (ii)
state machine reader, and (iii) profile reader. We use the
standard UML metamodel [22] to load the input models.
Class diagram reader uses UML class diagram metamodel to
Figure. 6. BoardSM class hierarchy generated code. load the instance of a class diagram. State machine reader
uses UML state machine metamodel to load the instances of
First of all we generate a base state class; for example for state machine. As our approach uses mobile UML profile for
Board class we generate a BoardState class. There is one to modeling, therefore the profile reader uses UML profile
one navigable relationship between Board and BoardState metamodel to load the instance of the profile. The output of
class, so both contains class property of each other. this process is the UML metamodel instances of the input
BoardState class contains all the methods in the Board class diagrams.
but they are empty and have no implementation. Each state
B. Mappings Resolver
in a state machine is transformed to a class inherited from the
base state class. Initialized, NewWordCreated, Validating, The mappings resolver is the second component in the
and Paused classes are generated and inherited from MAG tool. There are two inputs to this component: (i) UML
BoardState class as shown in Figure 6. The events on the metamodel instances of the class, state machine and profile
states are included as the methods in the specific classes. diagrams, and (ii) desired mobile platforms. The second
These methods are implemented in derived classes with their input provides information about the platforms for which the
corresponding actions. The guard maps to if-else blocks in mobile applications should be generated. This component is
their respective method. All ALF actions are transformed further divided into two sub-components: (i) cross-models
according to the mobile platform specific language. references resolver, and (ii) mobile platform mappings
resolver. The cross-models references resolver takes the
V. MOBILE APPLICATION GENERATOR UML metamodel instances as an input. It links the classes
To automate the mobile application generation process, with their specific state machines. It also links the
we have implemented MAG (Mobile Application stereotypes in the UML profile with their applied classes.

115
122
The mobile platform mappings resolveer resolves the approach. In this section, we demonstrate
d the mobile
mappings of different stereotypes to their relevant mobile application generation for multiplee platforms by using our
platform specific classes as presented in Tabble II. proposed approach and also comp parison with the original
scramble application. We analyze a the original
C. Application Generator implementation of scramble for An ndroid. It consists of over
The application generator is the finaal component in 12,000 lines of code. This included d code for both the GUI
MAG. It takes the linked UML metamodeel instances as an and the business logic, which was taangled together.
input which contains the complete informaation required to
generate mobile applications for multiple platforms. This
component further divided into four sub-components: (i)
structural code generator, (ii) behavioral codde generator, (iii)
code merger, and (iv) application configuratoor.

Figure. 9. Board class Windows Phone


P generated code.

We evaluated the model-driven n approach according to


two aspects. First, we evaluate whether our approach is able
to generate semantically equivalen nt code for the existing
application. Second, we generate the code for Windows
Figure. 8. Board class Android generateed code.
Phone platform from the same models to evaluate the
support of multiple platform applicaation generation.
Structural code generator generates thee structural code For the first part of the evaluatio
on, we needed to separate
for all the classes as discussed in the Sectiion IV. For each the business logic of the original sccramble application from
mobile application platform, it performss the same step the GUI. The GUI code was partiially rewritten to invoke
because every platform has different prograamming language various methods of a controller claass (BLController) that is
and API. Behavioral code generator generaates the dynamic generated by MAG tool. Next, we generated the application
code for all the state machines as discusseed in Section IV. code for Android from MAG. The generated
g code included a
Dynamic code includes the structural coode as per state controller class and various business b logic classes
pattern implementation as well as the class methods’ corresponding to the models sh hown earlier. The total
implementation. Code merger links the methods’ generated lines of code by our tool are
a approximately 2500.
implementation in their corresponding cclasses, such as, After integration, we executed the application and ran
Figure 8 shows the implementation of createeWord method. It several test cases on it. Test cases are
a based on the business
outputs the complete code file accordingg to the mobile scenarios that were used to build th he application by NextIn.
application platforms. As we are considering Android and The results of the test cases were equivalent to the actual
Windows Phone platforms, so this sub-com mponent generates application. This shows that the proposed model-driven
two code files. One is for Android platform in Java approach can successfully be used d for mobile application
programming language as Board class shoown in Figure 8. generation.
Second is for Windows Phone platform in C# programming For the second part of the evaluation, we generated the
language as Board class shown in Figuree 9. Application code for Windows Phone by selecting appropriate options in
configurator includes necessary configuurations in the the MAG tool. The GUI for Window ws Phone application was
generated file structure according to the mobbile platform. developed using Microsoft Visual Studio. The GUI code
called the various methods of contro oller class (BLController)
VI. EVALUATION to achieve the required functionality. This allowed the
We applied our approach on the indusstrial case study integration of the generated code wiith the GUI. We executed
described in Section II to demonstrate the appplicability of our similar test cases on the application and found that the results
are equivalent to the Android appllication. This shows that

116
123
our proposed approach supports generation of mobile to implement the communication between interface and
applications across multiple platforms. hardware. Min et al. present a UML metamodel based
approach to develop Windows Phone 7 applications [30].
VII. GENERATED APPLICATION VS. CURRENT UML profile is used to include the Windows Phone specific
DEVELOPMENT concepts.
Our proposed approach generates native mobile Kim et al. define a MDD approach to transform UML
applications for the different mobile platforms. Native diagrams to code for mobile application [31]. ATL is used
application is better in terms of performance as compared to for model-to-model while Acceleo is used for model-to-code
other mobile application types (i.e., web and hybrid). Native transformation. Sabraoui et al. generate GUI code for
application is developed using a platform specific API Android application using UML object diagram at
compiled to run on the platform rather than an interpreted metamodel level [32]. XMI is used to render the generated
language code, such as, Javascript [23]. The compiled code GUI on Android device. Son et al. propose a way to generate
directly interacts with the operating system and mobile method body for six different kinds of interactions in UML
device hardware allowing quick and efficient utilization of sequence diagram [33]. The transformation rules are defined
the mobile device resources, such as, Bluetooth and Wifi. using Acceleo.
Currently the mobile application industry is highly As mobile application development industry is growing
focused on producing mobile web applications because a rapidly, so there are numerous tools available to develop
single web application can run on multiple mobile platforms. mobile application for different platforms, such as,
The major limitation of mobile web applications is that they PhoneGap [34], Titanium [35], Adobe AIR [36], Sencha
cannot utilize the mobile platform specific libraries which Touch [37], and etc. Nearly all these tools use web-
results in low performance and inefficient utilization of interactive languages (i.e., Javascript [38], HTML5 [39], and
mobile device resources [4]. In case of support for bluetooth etc) which results in a development of mobile web
or camera, web applications rely on third-party components application. Although some of them allows support for the
which are provide low performance as compared to platform mobile platform native libraries in the application but the
specific library. Our proposed approach facilitates the resultant application cannot meet the performance and
generation of native mobile applications for multiple efficiency of native application because native application is
platforms, hence achieving the main goal of the mobile much better in look and feel than hybrid application. There
industry, i.e., reducing the effort of development and are some user interface interactive libraries available for
maintenance of an application for multiple platforms. It not developing mobile games or application (such as, CoCos2D
only improves the mobile device resource utilization [40], USIXML [41], and etc) but again the resultant
efficiency but also provides the facility to generate mobile application cannot meet the expectations of a native
applications for multiple platforms from the same business application.
logic model. As we generate executable business logic code To compare our proposed model-driven approach with
with the controller class as a code interface, the developers the existing literature, we allow platform independent
has the flexibility to develop user interfaces specific to a modeling hence facilitating application generation for
platform [23]. multiple platforms. To accommodate mobile domain specific
Our model-driven approach facilitates to develop concepts, we define mobile UML profile rather platform
different kinds of mobile application using the proposed specific profile. In comparison with available tools, we
mobile UML profile. We focus on the business logic layer, provide generation of native mobile applications using
so mobile platform specific constraints do not affect the platform specific API rather than web interactive languages.
modeling.
IX. CONCLUSION
VIII. RELATED WORK In this paper, we have proposed a model-driven approach
Kraemer use activity and state machine diagrams to for automated generation of mobile applications for multiple
develop Android application using Arctis SDK [24]. UML platforms. We use a carefully identified subset of UML that
Android profile is used for this purpose. UML class and fits our purpose of mobile application modeling. Real use-
sequence diagrams are used by Parada and Brisolara to cases are used for requirements modeling using application
design and develop Android application [25]. Android screens and UML use-case diagram. UML class diagram is
platform specific concepts (such as, activity, service, and etc) used for structural modeling. UML state machine diagrams
are integrated through inheritance. Cimino and Marcelloni are used for behavioral modeling. This is supported by
propose an MDA based approach using UIML language to executable models using action language ALF. We also
design UI for mobile application [26]. MODIF framework is proposed mobile UML profile to include mobile domain
used to transform UIML models to mobile platform specific specific concepts in mobile application modeling. We focus
code. Botturi et al. propose an approach to develop user on the modeling of business logic layer for the mobile
interface for mobile applications using UML profile [27]. application and provide a controller in the generated code to
Wang focus on using patterns for mobile application bridge the user interface with it. For the generation of mobile
designing [28]. Ko et al. propose a UML metamodel based application for multiple platforms automatically, we have
approach to develop Android applications [29]. MVC is used developed a prototype tool called MAG. The modeling
approach is applied on an industrial application ‘Scramble’

117
124
to demonstrate its applicability. The code for the case study [18] NextIn (2014, 23 - April). Available: http://www.nextin.co
is generated for two mobile platforms (i.e., Android and [19] Scramble (2014, 23 - April). Available:
http://www.amazon.com/Scramble-Kindle-Tablet-HD-
Windows Phone) using the same set of UML models. We HDx/dp/B00GHKO98Q/ref=sr_1_3?s=mobile-
also provide an evaluation of our generated code and apps&ie=UTF8&qid=1397135064&sr=1-3
integrated it with the existing application. This shows the [20] B. Selic, "A Systematic Approach to Domain-specific Language
viability of our approach. Design using UML," Proc. Object and Component-Oriented Real-
Time Distributed Computing, 2007. ISORC'07. 10th IEEE
ACKNOWLEDGMENT International Symposium on, 2007, pp. 2-9.
[21] M. Usman and A. Nadeem, "Automatic Generation of Java Code
We are thankful to our industrial partner, NextIn. The work from UML Diagrams using UJECTOR," International Journal of
presented here was supported by ICT R & D Fund, Pakistan Software Engineering and Its Applications, vol. 3, pp. 21-37, 2009.
(ICTRDF/MBTToolset/2013). Muhammad Zohaib Iqbal was [22] UML Superstructure v2.4.1 (2014, Aug). Available:
partly supported by National Research Fund, Luxembourg http://www.omg.org/spec/UML/2.4.1/Superstructure/PDF/
[23] A. Charland and B. Leroux, "Mobile Application Development: Web
(FNR/P10/03). vs. Native," Commun. ACM, vol. 54, pp. 49-53, 2011.
[24] F. Kraemer, "Engineering Android Applications based on UML
REFERENCES Activities," in Model Driven Engineering Languages and Systems.
[1] J. Dehlinger and J. Dixon, "Mobile Application Software vol. 6981, J. Whittle, T. Clark, and T. Kühne, Eds., ed: Springer
Engineering: Challenges and Research Directions," Proc. Workshop Berlin Heidelberg, 2011, pp. 183-197.
on Mobile Software Engineering, October, 2011. [25] A. G. Parada and L. B. d. Brisolara, "A Model Driven Approach for
[2] Global Mobile Statistics 2013 (2013, 13th - Dec). Available: Android Applications Development," Proc. Computing System
http://mobithinking.com/mobile-marketing-tools/latest-mobile-stats Engineering (SBESC), 2012 Brazilian Symposium on, 2012, pp. 192-
[3] M. E. Joorabchi, A. Mesbah, and P. Kruchten, "Real Challenges in 197.
Mobile App Development," Proc. 7th International Symposium on [26] M. G. Cimino and F. Marcelloni, "An Efficient Model-based
Empirical Software Engineering and Measurement (ESEM), Methodology for Developing Device-independent Mobile
Baltimore, Maryland, USA, October 2013. Applications," Journal of Systems Architecture, vol. 58, pp. 286-304,
[4] T. Wasserman, "Software Engineering Issues for Mobile Application 2012.
Development," FoSER 2010, 2010. [27] G. Botturi, E. Ebeid, F. Fummi, and D. Quaglia, "Model-driven
[5] B. Selic, "The Pragmatics of Model-driven Development," Software, Design for the Development of Multi-platform Smartphone
IEEE, vol. 20, pp. 19-25, 2003. Applications," Proc. Specification & Design Languages (FDL), 2013
[6] Unified Modeling language (UML), v2.4.1 (2013, 30th - Nov). Forum on, 2013, pp. 1-8.
Available: http://www.omg.org/spec/UML/2.4.1/ [28] Z. Wang, "The Study of Smart Phone Development based on UML,"
[7] H. Gomaa, "Model-based Software Design of Real-time Embedded Proc. Computer Science and Service System (CSSS), 2011
Systems," International Journal of Software Engineering, vol. 1, pp. International Conference on, 2011, pp. 2791-2794.
19-41, 2008. [29] M. Ko, Y.-J. Seo, B.-K. Min, S. Kuk, and H. S. Kim, "Extending
[8] C. Larman, Applying UML and Patterns: An Introduction to Object- UML Meta-model for Android Application," Proc. Computer and
Oriented Analysis and Design and Iterative Development, 3rd Information Science (ICIS), 2012 IEEE/ACIS 11th International
Edition, 3rd ed.: Prentice Hall, 2004. Conference on, 2012, pp. 669-674.
[9] M. Z. Iqbal, A. Arcuri, and L. Briand, "Environment Modeling and [30] B.-K. Min, M. Ko, Y. Seo, S. Kuk, and H. S. Kim, "A UML
Simulation for Automated Testing of Soft Real-time Embedded Metamodel for Smart Device Application Modeling based on
Software," Software & Systems Modeling, pp. 1-42, 2013. Windows Phone 7 Platform," Proc. TENCON 2011-2011 IEEE
[10] F. T. Balagtas-Fernandez and H. Hussmann, "Model-driven Region 10 Conference, 2011, pp. 201-205.
Development of Mobile Applications," Proc. Automated Software [31] W. Y. Kim, H. S. Son, J. S. Kim, and R. Y. C. Kim, "Adapting Model
Engineering, 2008. ASE 2008. 23rd IEEE/ACM International Transformation Approach for Android Smartphone Application," in
Conference on, 2008, pp. 509-512. Advanced Communication and Networking, ed: Springer, 2011, pp.
[11] D. Kramer, T. Clark, and S. Oussena, "MobDSL: A Domain Specific 421-429.
Language for Multiple Mobile Platform Deployment," Proc. [32] A. Sabraoui, M. E. Koutbi, and I. Khriss, "GUI Code Generation for
Networked Embedded Systems for Enterprise Applications (NESEA), Android Applications using a MDA Approach," Proc. Complex
2010 IEEE International Conference on, 2010, pp. 1-7. Systems (ICCS), 2012 International Conference on, 2012, pp. 1-6.
[12] A. Ribeiro and A. Silva, "XIS-Mobile: A DSL for Mobile [33] H. S. Son, W. Y. Kim, and R. Y. C. Kim, "MOF based Code
Applications," Proc. of SAC 2014 Conference, ACM, 2014. Generation Method for Android Platform," International Journal of
[13] Modeling and Analysis of Real-Time and Embedded Systems Software Engineering and Its Applications, vol. 7, p. 12, 2013.
(MARTE) v1.1 (2013, 30th - Nov). Available: [34] Phone Gap. Available: http://phonegap.com/
http://www.omg.org/spec/MARTE/1.1/PDF/ [35] Titanium. Available: http://www.appcelerator.com/titanium/
[14] M. Z. Iqbal, A. Arcuri, and L. Briand, "Empirical Investigation of [36] Adobe AIR (2014, 2nd July). Available:
Search Algorithms for Environment Model-based Testing of Real- http://www.adobe.com/products/air.html
time Embedded Software," Proc. of the 2012 International [37] Sencha Touch (2014, 2nd July). Available:
Symposium on Software Testing and Analysis, 2012, pp. 199-209. http://www.sencha.com/products/touch/
[15] Action Language for Fundamental UML (ALF) v1.0.1 (2013, 22th - [38] JavaScript v6. Available: http://www.w3schools.com/js/
Dec). Available: http://www.omg.org/spec/ALF/1.0.1/PDF/ [39] Hyper Text Markup Language (HTML), v5.0. Available:
[16] E. Gamma, R. Helm, R. Johnson, and J. Vlissides, Design Patterns: http://www.w3.org/TR/html5/
Elements of Reusable Object-Oriented Software: Pearson Education, [40] CoCos2D (2014, 2nd July). Available:
1994. https://code.google.com/p/cocos2d-android-1/
[17] Google Play Reaches 1 Million (2014, 23 - April). Available: [41] USIXML (USer Interface eXtensible Markup Language) (2014, 2nd
http://www.phonearena.com/news/Androids-Google-Play-beats-App- July). Available: http://www.usixml.org/en/home.html?IDC=221
Store-with-over-1-million-apps-now-officially-largest_id45680

118
125

You might also like