DOI QR코드

DOI QR Code

메시지 패턴에 기반한 UML 시퀀스 다이어그램의 자동 코드 생성 방법

A Method of Automatic Code Generation for UML Sequence Diagrams Based on Message Patterns

  • Kim, Yun-Ho (Department of Computer Engineering, Andong National University)
  • 투고 : 2020.04.22
  • 심사 : 2020.05.01
  • 발행 : 2020.07.31

초록

본 논문에서는 시퀀스 다이어그램의 메시지 패턴에 기반하여 자바 코드를 생성하는 방법을 제시하고자 한다. 시퀀스 다이어그램에서 메시지는 몇 가지 유형이 전형적으로 나타낸다. 따라서 이들 유형을 분류하여 패턴으로 정의하고, 이들 각 패턴의 메시지에 대한 정보를 분석하여 코드 변환을 하기 위한 메타 정보를 구축한다. 시퀀스 다이어그램 메시지의 구조적 정보를 분석한 '메타 메시지' 정보를 MetaMessage 데이터스토어에 구축하고, 이들 메타 메시지 정보로부터 구성되는 '메타 메소드' 정보를 MetaMethod 데이터스토어에 구축한다. 이 과정에서 메타 클래스 정보와 메타 오브젝트 정보가 함께 구축되고 사용된다. 각 패턴의 메타 정보에 기반하여 타겟 프로그래밍 언어의 문법에 따라 메시지에 상응하는 코드를 생성하게 된다. 또한, 기존 연구에서는 통합적으로 잘 다루지 않았던 분기와 반복에 대한 복합 패턴을 제시함으로써 기본 패턴과 통합된 코드 생성을 가능하게 한다.

This paper presents a method for code generation of UML sequence diagrams based on message patterns. In the sequence diagrams, it is shown that messages are some types of forms typically. This paper classifies according to type as three patterns, and construct meta-information for code generation analysing structural infomation for each patterns. The meta-message of structural information (MetaMessage) is stored in the MetaMessage datastore and the meta-method information from the MetaMessage is stored in the MetaMethod datastore. And then, the structural information of MetaClass and MetaObject is constructed in each datastore too. For each pattern, this paper presents a method for code generation based on the meta information of message patterns and the syntax of target progamming language. Also, branching and looping that has been seldom handled integratedly in the previous works are handled as same as the basic patterns by classifying the branching pattern and the looping pattern for code generation integratedly.

키워드

참고문헌

  1. Object Management Group (OMG), Unified Modeling Language Specification, Version 2.2, 2009.
  2. P. Pawde, V. Chole, "Generation of Java code structure from UML class diagrams," International Journal of Innovative Science and Modern Engineering, Vol. 2, No. 7, pp. 7-10, 2014.
  3. A. Soumiya, B. Mohamed, "Converting UML class diagrams into temporal object relational database," International Journal of Electrical and Computer Engineering, Vol. 7, No. 5, pp. 2823-2832, 2017. https://doi.org/10.11591/ijece.v7i5.pp2823-2832
  4. Y. Kim, "Information structuring of diagram repository for UML diagrams," Journal of the Korea Institute of Information and Communication Engineering, Vol. 23, No. 12, 2019.
  5. N. Sangal, E. Farrell, K. Lieberherr and D. Lorenz, "Interaction schema: Compiling interactioins to code," Proceedings of Technology of Object-Oriented Language and Systems, pp. 268-277, Aug., 1999.
  6. G. Engels, R. Hucking, S. Sauer, and A. Wagner, "UML collaboration diagrams and their transforamtion to Java," Second International Conference on the UML, pp. 437-488, 1999.
  7. G. Engels, R. Heekel, J. Kuster, "Reul-based Specification of behavioral consistency based on the UML meta-model," Fourth International Conference on the UML,, pp. 272-286, 2001.
  8. P. Kluisritrakul and Y. Limpiyakorn, "Generation of Java code from UML sequence and class diagrams," Information Science and Applications (ICISA), pp. 1117-1125, 2016.
  9. H. Zhang, "An approach for extracting UML diagram form object-oriented program based on J2X," Advances in Engineering Reseach (IFMCA), vol. 113, pp. 266-276, 2016.
  10. M. Qu, L. Meng, X. Wu and N. Cui, "Software Modeling and Automatic Code Generation Based on Reactive State Diagram," International Conference on Computer Information Systems and Industrial Applications, pp. 899-901, 2015.
  11. M. Mukhtar, B. Galadanci, "Automatic code generation from UML diagrams: The-State-of-the-art," Science World Journal, vol. 13, No. 4, pp. 47-60, 2018.
  12. E. Sunitha and P. Samuel, "Automatic code generation from UML state chart diagrams," IEEE Access, Vol. 7, pp. 8591 - 8608, 2019. https://doi.org/10.1109/ACCESS.2018.2890791
  13. Y. Kim, "A design of constructing diagram repository for UML diagram tools," Journal of the Korea Institute of Information and Communication Engineering, Vol. 24, No. 2, 2020.