Advertisement

SIGMA: Scala Internal Domain-Specific Languages for Model Manipulations

  • Filip Křikava
  • Philippe Collet
  • Robert B. France
Part of the Lecture Notes in Computer Science book series (LNCS, volume 8767)

Abstract

Model manipulation environments automate model operations such as model consistency checking and model transformation. A number of external model manipulation Domain-Specific Languages (DSL) have been proposed, in particular for the Eclipse Modeling Framework (EMF). While their higher levels of abstraction result in gains in expressiveness over general-purpose languages, their limitations in versatility, performance, and tool support together with the need to learn new languages may significantly contribute to accidental complexities.

In this paper, we present Sigma, a family of internal DSLs embedded in Scala for EMF model consistency checking, model-to-model and model-to-text transformations. It combines the benefits of external model manipulation DSLs with general-purpose programming taking full advantage of Scala versatility, performance and tool support. The DSLs are compared to the state-of-the-art Epsilon languages in non-trivial model manipulation tasks that resulted in 20% to 70% reduction in code size and significantly better performance.

Keywords

Object Constraint Language Object Management Group Eclipse Modeling Framework Common Infrastructure Model Navigation 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Apache Velocity, http://velocity.apache.org/
  2. 2.
  3. 3.
  4. 4.
    Paper Companion Web PageGoogle Scholar
  5. 5.
  6. 6.
    The Epsilon Project Documentation, http://eclipse.org/epsilon/doc/
  7. 7.
    The SALTY Project, https://salty.unice.fr
  8. 8.
  9. 9.
    The Unicaneer2sql Project, https://code.google.com/p/unicaneer2sql/
  10. 10.
    The YourCast Project, http://yourcast.fr/
  11. 11.
    Akehurst, D.H., Bordbar, B., Evans, M.J., Howells, W.G.J., McDonald-Maier, K.D.: SiTra: Simple Transformations in Java. In: Wang, J., Whittle, J., Harel, D., Reggio, G. (eds.) MoDELS 2006. LNCS, vol. 4199, pp. 351–364. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  12. 12.
    Burmako, E.: Scala macros: let our powers combine? In: Proceedings of the 4th Workshop on Scala (2013)Google Scholar
  13. 13.
    Chafi, H., DeVito, Z., Moors, A., Rompf, T., Sujeeth, A.K., Hanrahan, P., Odersky, M., Olukotun, K.: Language virtualization for heterogeneous parallel computing. In: Proceedings of the ACM International Conference on Object Oriented Programming Systems Languages and Applications (2010)Google Scholar
  14. 14.
    Cuadrado, J.S., Molina, J.G., Tortosa, M.M.: RubyTL: A Practical, Extensible Transformation Language. In: Rensink, A., Warmer, J. (eds.) ECMDA-FA 2006. LNCS, vol. 4066, pp. 158–172. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  15. 15.
    Czarnecki, K., Helsen, S.: Feature-based survey of model transformation approaches. IBM Systems Journal 45(3) (2006)Google Scholar
  16. 16.
    Dubochet, G.: Embedded Domain-Specific Languages using Libraries and Dynamic Metaprogramming. Ph.D. thesis, Ecole Polytechnique Fédérale de Lausanne (2011)Google Scholar
  17. 17.
    Fowler, M.: Domain Specific Languages, 1st edn. Addison-Wesley (2010)Google Scholar
  18. 18.
    George, L., Wider, A., Scheidgen, M.: Type-Safe Model Transformation Languages as Internal DSLs in Scala. In: Hu, Z., de Lara, J. (eds.) ICMT 2012. LNCS, vol. 7307, pp. 160–175. Springer, Heidelberg (2012)CrossRefGoogle Scholar
  19. 19.
    Horn, T., Krause, C., Rose, L.: 7th Transformation Tools Contest (2014)Google Scholar
  20. 20.
    Jouault, F., Kurtev, I.: Transforming Models with ATL. In: Bruel, J.-M. (ed.) MoDELS 2005 Workshops. LNCS, vol. 3844, pp. 128–138. Springer, Heidelberg (2006)Google Scholar
  21. 21.
    Kelly, S., Tolvanen, J.P.: Domain-Specific Modeling: Enabling Full Code Generation. Wiley-IEEE Computer Society Press (2008)Google Scholar
  22. 22.
    Kolovos, D.S., Paige, R.F., Polack, F.A.C.: The Epsilon Transformation Language. In: Vallecillo, A., Gray, J., Pierantonio, A. (eds.) ICMT 2008. LNCS, vol. 5063, pp. 46–60. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  23. 23.
    Kolovos, D.S., Paige, R.F., Polack, F.A.C.: The Epsilon Object Language (EOL). In: Rensink, A., Warmer, J. (eds.) ECMDA-FA 2006. LNCS, vol. 4066, pp. 128–142. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  24. 24.
    Kolovos, D.S., Paige, R.F., Polack, F.A.C.: On the Evolution of OCL for Capturing Structural Constraints in Modelling Languages. In: Abrial, J.-R., Glässer, U. (eds.) Büorger Festschrift. LNCS, vol. 5115, pp. 204–218. Springer, Heidelberg (2009)Google Scholar
  25. 25.
    Krikava, F.: Domain-Specific Modeling Language for Self-Adaptive Software System Architectures. Ph.D. thesis, University of Nice Sophia-Antipolis (2013)Google Scholar
  26. 26.
    Krikava, F., Collet, P.: On the Use of an Internal DSL for Enriching EMF Models. In: Proceedings of the 2012 International Workshop on OCL and Textual Modelling (2012)Google Scholar
  27. 27.
    Krikava, F., Collet, P., France, R.: ACTRESS: Domain-Specific Modeling of Self-Adaptive Software Architectures. In: Symposium on Applied Computing (SAC), track on Dependable and Adaptive Distributed Systems, DADS (2014)Google Scholar
  28. 28.
    Krikava, F., Collet, P., France, R.B.: Manipulating Models Using Internal Domain-Specific Languages. In: Symposium on Applied Computing (SAC), track on Programming Languages, PL (2014)Google Scholar
  29. 29.
    Mernik, M., Heering, J., Sloane, A.M.: When and how to develop domain-specific languages. ACM Comput. Surv. 37(4), 316–344 (2005)CrossRefGoogle Scholar
  30. 30.
    Moors, A., Rompf, T., Haller, P., Odersky, M.: Scala-virtualized. In: Proceedings of the ACM SIGPLAN 2012 Workshop on Partial Evaluation and Program Manipulation (2012)Google Scholar
  31. 31.
    Muller, P.-A., Fleurey, F., Jézéquel, J.-M.: Weaving executability into object-oriented meta-languages. In: Briand, L.C., Williams, C. (eds.) MoDELS 2005. LNCS, vol. 3713, pp. 264–278. Springer, Heidelberg (2005)CrossRefGoogle Scholar
  32. 32.
    Object Management Group: MOF Model to Text Transformation Language (MOFM2T). Tech. rep., Object Management Group (2008)Google Scholar
  33. 33.
    Object Management Group: MOFTM Query / View / Transformation (QVT). Tech. rep., Object Management Group (2011)Google Scholar
  34. 34.
    Object Management Group: OMG Object Constraint Language (OCL). Tech. rep., Object Management Group (2012)Google Scholar
  35. 35.
    Odersky, M., Altherr, P., Cremet, V., Emir, B., Maneth, S., Micheloud, S., Mihaylov, N., Schinz, M., Stenman, E., Zenger, M.: An Overview of the Scala Programming Language. Tech. rep., École Polytechnique Fédérale de Lausanne (2014)Google Scholar
  36. 36.
    Paige, R.F., Kolovos, D.S., Rose, L.M., Drivalos, N., Polack, F.A.C.: The Design of a Conceptual Framework and Technical Infrastructure for Model Management Language Engineering. In: 2009 14th IEEE International Conference on Engineering of Complex Computer Systems (2009)Google Scholar
  37. 37.
    Rompf, T., Odersky, M.: Lightweight modular staging: A pragmatic approach to runtime code generation and compiled DSLs. In: Proceedings of the Ninth International Conference on Generative Programming and Component Engineering (2010)Google Scholar
  38. 38.
    Rose, L.M., Paige, R.F., Kolovos, D.S., Polack, F.A.C.: The Epsilon Generation Language. In: Schieferdecker, I., Hartman, A. (eds.) ECMDA-FA 2008. LNCS, vol. 5095, pp. 1–16. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  39. 39.
    Sánchez Cuadrado, J., Canovas, J., Garcia Molina, J.: Comparison between internal and external DSLs via RubyTL and Gra2MoL. In: Mernik, M. (ed.) Formal and Practical Aspects of Domain-Specific Languages: Recent Developments. IGI Global (2012)Google Scholar
  40. 40.
    Schmidt, D.C.: Guest Editor’s Introduction: Model-Driven Engineering. Computer 39(2) (2006)Google Scholar
  41. 41.
    Sendall, S., Kozaczynski, W.: Model transformation: The heart and soul of model-driven software development. IEEE Software 20(5), 3 (2000)Google Scholar
  42. 42.
    Siek, J.G.: General purpose languages should be metalanguages. In: Proceedings of the 2010 ACM SIGPLAN Workshop on Partial Evaluation and Program Manipulation (2010)Google Scholar
  43. 43.
    Steinberg, D., Budinsky, F., Paternostro, M., Merks, E.: EMF: Eclipse Modeling Framework, 2nd edn. Addison-Wesley Professional (2008)Google Scholar
  44. 44.
    Wider, A.: Towards combinators for bidirectional model transformations in scala. Software Language Engineering (2011)Google Scholar
  45. 45.
    Zibin, Y., Potanin, A., Ali, M., Artzi, S., Kieżun, A., Ernst, M.D.: Object and reference immutability using java generics. In: Proceedings of the the 6th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on The Foundations of Software Engineering (2007)Google Scholar

Copyright information

© Springer International Publishing Switzerland 2014

Authors and Affiliations

  • Filip Křikava
    • 1
  • Philippe Collet
    • 2
  • Robert B. France
    • 3
  1. 1.University Lille 1 / LIFL Inria LilleNord EuropeFrance
  2. 2.Université Nice Sophia Antipolis / I3S - CNRS UMR 7271Sophia AntipolisFrance
  3. 3.Computer Science DepartmentColorado State UniversityFort CollinsUSA

Personalised recommendations