Advertisement

An Approach to the Validation of XML Documents Based on the Model Driven Architecture and the Object Constraint Language

  • Denis A. Nikiforov
  • Dmitriy V. Korj
  • Ruslan L. Sivakov
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 10742)

Abstract

It is possible to develop data processing applications using a variety of different data representation formats (EDI, CSV, XML, JSON), domain-specific languages, and general-purpose programming languages (XSLT, SQL, Java, C#). On the one hand, such a variety allows one to choose the most optimal data format or language based on the specific requirements being applied, while on the other one, contemporary information systems or complexes of integrated information systems have become similar to the Tower of Babel, being so cumbersome to build and maintain. A possible solution to this issue could be found in developing platform-independent specifications to be used for generating the source code for each required platform.

This article describes an approach to the XML document validators’ generation based on UML models with Object Constraint Language (OCL) rules. The authors give a brief account of similar tools and propose a generalized schema for generating the validators based on a model-driven approach. The core component of this schema is the transformation of OCL constraints to XPath assertions. The first ones could come from one of the supported platform-independent models (Eurasian Economic Union Data Model or ISO 20022), while the later could be embedded into XML Schema 1.1, XSLT or Java code.

The transformation is implemented at the model level in the Query/View/Transformation language. The article does not go into details of converting OCL into XPath, because such a description takes up a lot of space and has already been given in similar articles. The authors describe only the key features of their approach: development of metamodels for XPath, XSD 1.1, and XSLT, support of a variety of platform-independent and platform-specific models, determination of elements subject to validation, external data sources, kinds of validation messages, preconditions.

Keywords

XML validation Semantic validation Unified Modeling Language Object Constraint Language XPath XML Schema XSLT Model Driven Architecture Platform-independent model Metamodel Model transformation Query/View/Transformation Eclipse Modeling Framework ISO 20022 

References

  1. 1.
    Cabot, J., Teniente, E.: Constraint support in MDA tools: a survey. In: Rensink, A., Warmer, J. (eds.) ECMDA-FA 2006. LNCS, vol. 4066, pp. 256–267. Springer, Heidelberg (2006).  https://doi.org/10.1007/11787044_20 CrossRefGoogle Scholar
  2. 2.
    Chiorean, D., Bortes, M., Corutiu, D.: Object constraint language environment, a tool supporting teaching and learning UML and OCL, the understanding and using of metamodeling, abstraction and design by contract. In: Eight Workshop on Pedagogies and Tools for Teaching and Learning Object Oriented Concepts (2000)Google Scholar
  3. 3.
    Demuth, B., Hussmann, H., Loecher, S.: OCL as a specification language for business rules in database applications. In: Gogolla, M., Kobryn, C. (eds.) UML 2001. LNCS, vol. 2185, pp. 104–117. Springer, Heidelberg (2001).  https://doi.org/10.1007/3-540-45441-1_9 CrossRefGoogle Scholar
  4. 4.
    Djurić, D., Gaševic, D., Devedžic, V.: The tao of modeling spaces. J. Object Technol. 5, 125–147 (2006)CrossRefGoogle Scholar
  5. 5.
    Gaafar, A., Sakr, S.: Towards a framework for mapping between UML/OCL and XML/XQuery. In: Baar, T., Strohmeier, A., Moreira, A., Mellor, S.J. (eds.) UML 2004. LNCS, vol. 3273, pp. 241–259. Springer, Heidelberg (2004).  https://doi.org/10.1007/978-3-540-30187-5_18 Google Scholar
  6. 6.
    Gronback, R.C.: Eclipse Modeling Project: A Domain-Specific Language (DSL) Toolkit. Addison-Wesley Professional, Boston (2009)Google Scholar
  7. 7.
    Heidenreich, F., Johannes, J., Seifert, M., Wende, C.: Construct to reconstruct - reverse engineering Java code with JaMoPP. In: Reverse Engineering Models from Software Artifacts - REM 2009 (2009)Google Scholar
  8. 8.
    Henriksson, J., Heidenreich, F., Johannes, J., Zschaler, S., Abmann, U.: Extending grammars and metamodels for reuse: the Reuseware approach. IET Softw. 2(3), 165–184 (2008)CrossRefGoogle Scholar
  9. 9.
    ISO: Financial services - Universal financial industry message scheme - Part 1: Metamodel. ISO 20022–1, International Organization for Standardization (2003)Google Scholar
  10. 10.
    ISO: Information technology - Document Schema Definition Languages (DSDL) - Part 3: Rule-based validation - Schematron. ISO/IEC 19757–3:2016, International Organization for Standardization (2016)Google Scholar
  11. 11.
    Klmek, J., Malý, J., Necaský, M., Holubová, I.: eXolutio: methodology for design and evolution of XML schemas using conceptual modeling. Inform. Lith. Acad. Sci. 26, 453–472 (2015)Google Scholar
  12. 12.
    Korchagin, A.B., Lisikh, I.G., Nikiforov, D.A., Sivakov, R.L.: Data models for information exchange. Int. J. Open Inf. Technol. 5(3), 49–55 (2017)Google Scholar
  13. 13.
    Malý, J.: XML Document Adaptation and Integrity Constraints in XML. Ph.D. thesis, Charles University in Prague (2013)Google Scholar
  14. 14.
    Malý, J., Nečaský, M.: Evaluation of OCL expressions over XML data model. J. Univ. Comput. Sci. 20, 329–365 (2014)Google Scholar
  15. 15.
    Miller, J., Mukerji, J.: MDA guide version 1.0.1 (2003). http://www.omg.org/cgi-bin/doc?omg/03-06-01
  16. 16.
    Moskal, J., Kokar, M., Morgan, J.: Semantic validation of T&E XML data. In: International Telemetering Conference Proceedings, International Foundation for Telemetering, October 2015Google Scholar
  17. 17.
    Nikiforov, D.A.: Development of metamodels using the Eclipse Modeling Framework, September 2015. https://habrahabr.ru/company/cit/blog/266433/
  18. 18.
    Nikiforov, D.A.: An introduction to the development of DSLs using EMFText, November 2015. https://habrahabr.ru/company/cit/blog/270483/
  19. 19.
    Nikiforov, D.A.: The Object Constraint Language, August 2015. https://habrahabr.ru/company/cit/blog/264963/
  20. 20.
    Nikiforov, D.A.: Development of the parser, printer, and editor for SQL using EMFText, December 2016. https://habrahabr.ru/company/cit/blog/271945/
  21. 21.
    Nikiforov, D.A.: Ecore-based metamodels of XML Schema 1.1 and XSLT 2.0, February 2017. https://doi.org/10.5281/zenodo.291483
  22. 22.
    Nikiforov, D.A.: The EMFText-based metamodel, parser, and printer of XPath 2.0, February 2017. https://doi.org/10.5281/zenodo.291481
  23. 23.
    Nikiforov, D.A.: UML to XML Schema 1.1 transformation, version 1.1, February 2017. https://doi.org/10.5281/zenodo.291482
  24. 24.
    Nikiforov, D.A., Korchagin, A.B., Sivakov, R.L.: An ontology-driven approach to electronic document structure design. In: Ignatov, D.I., Khachay, M.Y., Labunets, V.G., Loukachevitch, N., Nikolenko, S.I., Panchenko, A., Savchenko, A.V., Vorontsov, K. (eds.) AIST 2016. CCIS, vol. 661, pp. 3–16. Springer, Cham (2017).  https://doi.org/10.1007/978-3-319-52920-2_1 CrossRefGoogle Scholar
  25. 25.
    Nikiforov, D.A., Korj, D.V., Sivakov, R.L.: A survey of tools for XML validation based on the object constraint language (OCL). Inf. Technol. 23(5), 342–351 (2017)Google Scholar
  26. 26.
    OMG: Object Constraint Language (OCL), version 2.4. Specification, Object Management Group (2014)Google Scholar
  27. 27.
    OMG: UML Profile for National Information Exchange Model (NIEM), version 3.0. Specification, Object Management Group (2015)Google Scholar
  28. 28.
    OMG: Unified Modeling Language (UML), version 2.5. Specification, Object Management Group (2015)Google Scholar
  29. 29.
    OMG: XML Metadata Interchange (XMI), version 2.5.1. Specification, Object Management Group (2015)Google Scholar
  30. 30.
    OMG: Meta Object Facility (MOF) 2.0 Query/View/Transformation, version 1.3. Specification, Object Management Group (2016)Google Scholar
  31. 31.
    Steinberg, D., Budinsky, F., Paternostro, M., Merks, E.: EMF: Eclipse Modeling Framework 2.0, 2nd edn. Addison-Wesley Professional, Reading (2009)Google Scholar

Copyright information

© Springer International Publishing AG 2018

Authors and Affiliations

  • Denis A. Nikiforov
    • 1
  • Dmitriy V. Korj
    • 1
  • Ruslan L. Sivakov
    • 1
  1. 1.Center of Information Technologies LLCEkaterinburgRussia

Personalised recommendations