Translating UML-RSDS OCL to ANSI C

  • Kevin LanoEmail author
  • Sobhan Yassipour-Tehrani
  • Hessa Alfraihi
  • Shekoufeh Kolahdouz-Rahimi
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 10748)


In this paper we describe a transformation from a subset of OCL to ANSI C code, and we show that the generated code provides improved efficiency compared to OCL execution using Java, C# or C++. The transformation is itself formally specified using OCL.


  1. 1.
    Cuadrado, J., Jouault, F., Molina, J., Bezivin, J.: Deriving OCL optimisation patterns from benchmarks. In: OCL 2008 (2008)Google Scholar
  2. 2.
    Dieumegard, A., Toon, A., Pantel, M.: Model-based formal specification of a DSL library for a qualified code generator. In: OCL 2012 (2012)Google Scholar
  3. 3.
    Funk, M., Nysen, A., Lichter, H.: From UML to ANSI-C: an Eclipse-based code generation framework. RWTH (2007)Google Scholar
  4. 4.
    Kernighan, B., Ritchie, D.: The C Programming Language. Prentice Hall, Upper Saddle River (1988)zbMATHGoogle Scholar
  5. 5.
    Kuhlmann, M., Hamann, L., Gogolla, M., Buttner, F.: A benchmark for OCL engine accuracy, determinateness and efficiency. SoSyM 11, 165–182 (2012)Google Scholar
  6. 6.
    Lano, K.: Agile Model-Based Development Using UML-RSDS. Taylor and Francis, Milton Park (2016)CrossRefGoogle Scholar
  7. 7.
    OMG: OCL Version 2.4 (2014)Google Scholar
  8. 8.
    OMG: Semantics of a Foundational Subset for Executable UML Models (FUML), v1.1 (2015)Google Scholar
  9. 9.
    Zschaler, S., Poernomo, I., Terrell, J.: Towards using constructive type theory for verifable modular transformations. In: FREECO 2011 (2011)Google Scholar
  10. 10.
    Willink, E.: An extensible OCL virtual machine and code generator. In: OCL 2012 (2012)Google Scholar

Copyright information

© Springer International Publishing AG 2018

Authors and Affiliations

  • Kevin Lano
    • 1
    Email author
  • Sobhan Yassipour-Tehrani
    • 1
  • Hessa Alfraihi
    • 1
  • Shekoufeh Kolahdouz-Rahimi
    • 2
  1. 1.Department of InformaticsKing’s College LondonLondonUK
  2. 2.Department of Software EngineeringUniversity of IsfahanIsfahanIran

Personalised recommendations