Developing mobile applications remains difficult, time consuming, and error prone, in spite of the number of existing platforms and tools. In this paper, we develop MoDroid, a high-level modeling language to ease the development of Android applications. MoDroid allows developing models representing the core of applications. MoDroid provides Android programmers with the following advantages: (1) models are built using high-level primitives that abstract away several implementation details; (2) it allows the definition of interfaces between models to automatically compose them; (3) a native Android application can be automatically generated along with the required permissions definition; (4) it supports efficient testing execution that operates on models. MoDroid is fully implemented and was used to develop several non-trivial Android applications.
This is a preview of subscription content, log in to check access.
Buy single article
Instant access to the full article PDF.
Price includes VAT for USA
Subscribe to journal
Immediate online access to all issues from 2019. Subscription will auto renew annually.
This is the net price. Taxes to be calculated in checkout.
Amalfitano, D., Fasolino, A.R., Tramontana, P., Ta, B.D., Memon, A.M.: Mobiguitar–a tool for automated model-based testing of mobile apps. IEEE Softw, NN(N), NN-NN (2014)
Apache. Cordova (2011). http://cordova.apache.org/
Au, K.W.Y., Zhou, Y.F., Huang, Z., Lie, D.: Pscout: analyzing the android permission specification. In: Proceedings of the 2012 ACM conference on Computer and communications security, pp. 217–228. ACM, New York (2012)
Bartel, A., Klein, J., Le Traon, Y., Monperrus, M.: Automatically securing permission-based software by reducing the attack surface: an application to android. In: Proceedings of the 27th IEEE/ACM International Conference on Automated Software Engineering, pp. 274–277. ACM, New York (2012)
EclEmma. Jacoco java code coverage library
Feng, Y., Anand, S., Dillig, I., Aiken, A.: Semantics-based detection of android malware through static analysis. In: SIGSOFT FSE, Apposcopy (2014)
Eclipse Foundation. Xcore is an extended concrete syntax for ecore that, in combination with xbase, transforms it into a fully fledged programming language with high quality tools reminiscent of the java development tools (2011)
Google. Testing instrumentation (2007)
Google. Application exerciser monkey (2010)
Google. Layout editor (2011). https://developer.android.com/studio/write/layout-editor.html
Google. Espresso (2013)
jQuery Team. Jquery mobile (2010). http://www.jquerymobile.com/
Pivotal Labs. Robolectric (2010)
Mitchell, E.: App Inventor 2: Tutorial: The fast and easy way to create Android apps, vol. 1 (2014)
Palmieri, M., Singh, I., Cicchetti, A.: Comparison of cross-platform mobile development tools. In: 16th International Conference on Intelligence in Next Generation Networks, ICIN 2012, pp. 179–186. Berlin, Germany (2012)
Terence Parr. String template (2000)
Renas Reda. Robotium (2009)
Rösler, F., Nitze, A., Schmietendorf, A.: Towards a mobile application performance benchmark. In: ICIW 2014, The Ninth International Conference on Internet and Web Applications and Services, pp. 55–59 (2014)
Steinberg, D., Budinsky, F., Merks, E., Paternostro, M.: EMF: eclipse modeling framework. Pearson Education, USA (2003)
Adobe Systems. Phonegap (2009). http://www.phonegap.com/
Wolf, F., Huffstadt, K.: Mobile enterprise application development-a cross-platform framework. FHWS Sci. J. 33 (2013)
Yang, W., Prasad, M.R., Xie, T.: A grey-box approach for automated gui-model generation of mobile applications. Fundamental Approaches to Software Engineering–16th International Conference. FASE 2013, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2013, Proceedings, pp. 250–265. Italy, Rome (2013)
Zheng, Y., Kell, S., Bulej, L., Sun, H., Binder, W.: Comprehensive multi-platform dynamic program analysis for java and android. IEEE Softw. (99), 1 (2015)
Zneika, M., Loulou, H., Houacine, F., Bouzefrane, S.: Towards a modular and lightweight model for android development platforms. In: IEEE International Conference on Green Computing and Communications and IEEE Internet of Things and IEEE Cyber, Physical and Social Computing, pp. 2129–2132 (2013)
We show a small example to showcase syntax used in MoDroid. Moreover, we show parts of the generated application structure. We emphasize the simplicity and readability of generated code. This ensures that developers have the ability to modify and edit the generated code if they want to. Line-by-line traceability of the generated handlers to the original code is also clear. We also show the generated manifest and the detected permission as well.
Listings 18 and 19 contains the full code of the MoDroid model. The model represents a simple two-activity application. The first activity contains a simple login screen, upon submitting the application moves to the second activity, and displays the username used. Listing 19 also contains the generated code for the handlers.
The generated application has the following structure:
Listing 17 shows the generated manifest that contains the required permissions and information about the activities of the application. Clearly, developing this application using native Android is more complex and more time consuming than using MoDroid. This is mainly due to the following: (1) native Android requires more code (up to four times more) than MoDroid; (2) we should manually write configuration file with the proper permissions which is automatically generated in case of MoDroid; (3) testing using native Android requires extra configurations and running tests will take place on emulators. On the contrary, testing using MoDroid does not require any extra configuration. Moreover, running tests will be directly simulated on the underlying model which is much more efficient that running them on emulators.
About this article
Cite this article
Jaber, M., Falcone, Y., Dak-Al-Bab, K. et al. A high-level modeling language for the efficient design, implementation, and testing of Android applications. Int J Softw Tools Technol Transfer 20, 1–18 (2018). https://doi.org/10.1007/s10009-016-0441-2