Skip to main content

Translating OCL to Graph Patterns

  • Conference paper
Book cover Model-Driven Engineering Languages and Systems (MODELS 2014)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 8767))

Abstract

Model-driven tools use model queries for many purposes, including validation of well-formedness rules and specification of derived features. The majority of declarative model query corpus available in industry appears to use the OCL language. Graph pattern based queries, however, would have a number of advantages due to their more abstract specification, such as performance improvements through advanced query evaluation techniques. As query performance can be a key issue with large models, evaluating graph patterns instead of OCL queries could be useful in practice.

The current paper presents an automatic mapping from a large sublanguage of OCL expressions to equivalent graph patterns in the dialect of EMF-IncQuery. Validation of benefits is carried out by performance measurements according to an existing benchmark.

This work was partially supported by the European Union and the State of Hungary, co-financed by the European Social Fund in the framework of TÁMOP 4.2.4. A/-11-1-2012-0001 ‘National Excellence Program’, and by the CERTIMOT (ERC_HU-09-01-2010-0003) and EU FP7 MONDO (ICT-2013.1.2) projects.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. The Eclipse Foundation: Eclipse Modeling Framework, http://www.eclipse.org/emf/

  2. Eclipse Model Development Tools Project: MDT-OCL website (2011), http://www.eclipse.org/modeling/mdt/?project=ocl

  3. Ehrig, H., Engels, G., Kreowski, H.J., Rozenberg, G. (eds.): Handbook on Graph Grammars and Computing by Graph Transformation: Applications, Languages and Tools, 2nd edn. World Scientific (1999)

    Google Scholar 

  4. Rensink, A.: Representing first-order logic using graphs. In: Ehrig, H., Engels, G., Parisi-Presicce, F., Rozenberg, G. (eds.) ICGT 2004. LNCS, vol. 3256, pp. 319–335. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

  5. W3C SPARQL Working Group: SPARQL Query Language for RDF. Technical report, W3C (2008), http://www.w3.org/TR/rdf-sparql-query/

  6. Horváth, Á., Varró, G., Varró, D.: Generic search plans for matching advanced graph patterns. In: Proc. of the Sixth International Workshop on Graph Transformation and Visual Modeling Techniques (GT-VMT 2007), pp. 57–68. Electornic Communications of the EASST, Braga (2007)

    Google Scholar 

  7. Veit Batz, G., Kroll, M., Geiß, R.: A first experimental evaluation of search plan driven graph pattern matching. In: Schürr, A., Nagl, M., Zündorf, A. (eds.) AGTIVE 2007. LNCS, vol. 5088, pp. 471–486. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

  8. Giese, H., Hildebrandt, S., Seibel, A.: Improved flexibility and scalability by interpreting story diagrams. ECEASST 18 (2009)

    Google Scholar 

  9. Forgy, C.L.: Rete: A fast algorithm for the many pattern/many object pattern match problem. Artificial Intelligence 19(1), 17–37 (1982)

    Article  Google Scholar 

  10. Ujhelyi, Z., Bergmann, G., Hegedüs, Á., Horváth, Á., Izsó, B., Ráth, I., Szatmári, Z., Varró, D.: EMF-IncQuery: An integrated development environment for live model queries. Science of Computer Programming (0) (2014)

    Google Scholar 

  11. Hegedüs, Á., Horváth, Á., Ráth, I., Varró, D.: A model-driven framework for guided design space exploration. In: 26th IEEE/ACM International Conference on Automated Software Engineering (ASE 2011). IEEE Computer Society, Lawrence (2011)

    Google Scholar 

  12. Rensink, A., Distefano, D.: Abstract graph transformation. Electron. Notes Theor. Comput. Sci. 157(1), 39–59 (2006)

    Article  Google Scholar 

  13. Baldan, P., Corradini, A., König, B.: Unfolding graph transformation systems: Theory and applications to verification. In: Degano, P., De Nicola, R., Meseguer, J. (eds.) Montanari Festschrift. LNCS, vol. 5065, pp. 16–36. Springer, Heidelberg (2008)

    Google Scholar 

  14. Heckel, R., Küster, J.M., Taentzer, G.: Confluence of typed attributed graph transformation systems. In: Corradini, A., Ehrig, H., Kreowski, H.-J., Rozenberg, G. (eds.) ICGT 2002. LNCS, vol. 2505, pp. 161–176. Springer, Heidelberg (2002)

    Chapter  Google Scholar 

  15. Winkelmann, J., Taentzer, G., Ehrig, K., Küster, J.M.: Translation of Restricted OCL Constraints into Graph Constraints for Generating Meta Model Instances by Graph Grammars. In: Proceedings of the Fifth International Workshop on Graph Transformation and Visual Modeling Techniques (GT-VMT 2006), vol. 211, pp. 159–170. Elsevier Science Publishers B. V., Amsterdam (2008)

    Google Scholar 

  16. Anastasakis, K., Bordbar, B., Georg, G., Ray, I.: UML2Alloy: A challenging model transformation. In: Engels, G., Opdyke, B., Schmidt, D.C., Weil, F. (eds.) MODELS 2007. LNCS, vol. 4735, pp. 436–450. Springer, Heidelberg (2007)

    Chapter  Google Scholar 

  17. Object Management Group: Object Constraint Language Specification, Version 2.4 (2014), http://www.omg.org/spec/OCL/2.4/

  18. Bergmann, G., Ujhelyi, Z., Ráth, I., Varró, D.: A graph query language for EMF models. In: Cabot, J., Visser, E. (eds.) ICMT 2011. LNCS, vol. 6707, pp. 167–182. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  19. Bergmann, G., Horváth, Á., Ráth, I., Varró, D.: A benchmark evaluation of incremental pattern matching in graph transformation. In: Ehrig, H., Heckel, R., Rozenberg, G., Taentzer, G. (eds.) ICGT 2008. LNCS, vol. 5214, pp. 396–410. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

  20. Ráth, I., Hegedüs, Á., Varró, D.: Derived features for EMF by integrating advanced model queries. In: Vallecillo, A., Tolvanen, J.-P., Kindler, E., Störrle, H., Kolovos, D. (eds.) ECMFA 2012. LNCS, vol. 7349, pp. 102–117. Springer, Heidelberg (2012)

    Chapter  Google Scholar 

  21. Bergmann, G.: Incremental model queries in model-driven design. Ph.D. dissertation, Budapest University of Technology and Economics, Budapest (October 2013)

    Google Scholar 

  22. Bergmann, G.: Graph patterns from OCL: A performance evaluation (March 2014), https://incquery.net/content/graph-patterns-ocl-performance-evaluation .

  23. Bergmann, G., Ráth, I., Szabó, T., Torrini, P., Varró, D.: Incremental pattern matching for the efficient computation of transitive closure. In: Ehrig, H., Engels, G., Kreowski, H.-J., Rozenberg, G. (eds.) ICGT 2012. LNCS, vol. 7562, pp. 386–400. Springer, Heidelberg (2012)

    Chapter  Google Scholar 

  24. Groher, I., Reder, A., Egyed, A.: Incremental consistency checking of dynamic constraints. In: Rosenblum, D.S., Taentzer, G. (eds.) FASE 2010. LNCS, vol. 6013, pp. 203–217. Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  25. Brucker, A.D., Doser, J., Wolff, B.: Semantic issues of OCL: Past, present, and future. In: 6th OCL Workshop at the UML/MoDELS Conference (2006)

    Google Scholar 

  26. Uhl, A., Goldschmidt, T., Holzleitner, M.: Using an OCL Impact Analysis Algorithm for View-Based Textual Modelling. In: Proc. 11th workshop on OCL and Textual Modelling (OCL 2011), vol. 44. ECEASST (2011)

    Google Scholar 

  27. Cabot, J., Clarisó, R., Riera, D.: Verification of UML/OCL class diagrams using constraint programming. In: Proceedings of the 2008 IEEE International Conference on Software Testing Verification and Validation Workshop, ICSTW 2008, pp. 73–80. IEEE Computer Society, Washington, DC (2008)

    Chapter  Google Scholar 

  28. Cabot, J., Teniente, E.: Incremental integrity checking of UML/OCL conceptual schemas. J. Syst. Softw. 82(9), 1459–1478 (2009)

    Article  Google Scholar 

  29. Reder, A., Egyed, A.: Incremental consistency checking for complex design rules and larger model changes. In: France, R.B., Kazmeier, J., Breu, R., Atkinson, C. (eds.) MODELS 2012. LNCS, vol. 7590, pp. 202–218. Springer, Heidelberg (2012)

    Chapter  Google Scholar 

  30. Bergmann, G., Horváth, Á., Ráth, I., Varró, D., Balogh, A., Balogh, Z., Ökrös, A.: Incremental evaluation of model queries over EMF models. In: Petriu, D.C., Rouquette, N., Haugen, Ø. (eds.) MODELS 2010, Part I. LNCS, vol. 6394, pp. 76–90. Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  31. Izsó, B., Szatmári, Z., Bergmann, G., Horváth, Á., Ráth, I.: Towards precise metrics for predicting graph query performance. In: 2013 IEEE/ACM 28th International Conference on Automated Software Engineering (ASE), pp. 412–431. IEEE Computer Society Press, Silicon Valley (2013)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2014 Springer International Publishing Switzerland

About this paper

Cite this paper

Bergmann, G. (2014). Translating OCL to Graph Patterns. In: Dingel, J., Schulte, W., Ramos, I., Abrahão, S., Insfran, E. (eds) Model-Driven Engineering Languages and Systems. MODELS 2014. Lecture Notes in Computer Science, vol 8767. Springer, Cham. https://doi.org/10.1007/978-3-319-11653-2_41

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-11653-2_41

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-11652-5

  • Online ISBN: 978-3-319-11653-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics