Typing Requirement Model as Coroutines (2405.10060v1)
Abstract: Model-Driven Engineering (MDE) is a technique that aims to boost productivity in software development and ensure the safety of critical systems. Central to MDE is the refinement of high-level requirement models into executable code. Given that requirement models form the foundation of the entire development process, ensuring their correctness is crucial. RM2PT is a widely used MDE platform that employs the REModel language for requirement modeling. REModel contains contract sections and other sections including a UML sequence diagram. This paper contributes a coroutine-based type system that represents pre- and post-conditions in the contract sections in a requirement model as the receiving and yielding parts of coroutines, respectively. The type system is capable of composing coroutine types, so that users can view functions as a whole system and check their collective behavior. By doing so, our type system ensures that the contracts defined in it are executed as outlined in the accompanied sequence diagram. We assessed our approach using four case studies provided by RM2PT, validating the accuracy of the models.
- F. Zalila, “Methods and tools for the integration of formal verification in domain-specific languages,” Ph.D. dissertation, Institut National Polytechnique De Toulouse, Toulouse, France, 2014.
- S. Abrahão, F. Bourdeleau, B. Cheng, S. Kokaly, R. Paige, H. Stöerrle, and J. Whittle, “User experience for model-driven engineering: Challenges and future directions,” in 2017 ACM/IEEE 20th International Conference on Model Driven Engineering Languages and Systems (MODELS). IEEE, 2017, pp. 229–236. [Online]. Available: http://doi.org/10.1109/MODELS.2017.5
- H. F. Hofmann and F. Lehner, “Requirements engineering as a success factor in software projects,” IEEE software, vol. 18, no. 4, pp. 58–66, 2001. [Online]. Available: http://doi.org/10.1109/MS.2001.936219
- F. Zalila, X. Crégut, and M. Pantel, “Leveraging formal verification tools for dsml users: a process modeling case study,” in Leveraging Applications of Formal Methods, Verification and Validation. Applications and Case Studies: 5th International Symposium, ISoLA 2012, Heraklion, Crete, Greece, October 15-18, 2012, Proceedings, Part II 5. Springer, 2012, pp. 329–343. [Online]. Available: https://doi.org/10.1007/978-3-642-34032-1_34
- G. Atladottir, E. T. Hvannberg, and S. Gunnarsdottir, “Comparing task practicing and prototype fidelities when applying scenario acting to elicit requirements,” Requirements Engineering, vol. 17, pp. 157–170, 2012. [Online]. Available: https://doi.org/10.1007/s00766-011-0131-2
- Y. Yang, X. Li, W. Ke, and Z. Liu, “Automated prototype generation from formal requirements model,” IEEE Transactions on Reliability, vol. 69, no. 2, pp. 632–656, 2019. [Online]. Available: https://doi.org/10.1109/TR.2019.2934348
- Q. Gu, W. Ke, and Y. Yang, “Transformation from mvc applications to smart contracts,” in 2022 IEEE 20th International Conference on Embedded and Ubiquitous Computing (EUC). IEEE, 2022, pp. 104–111. [Online]. Available: https://doi.org/10.1109/EUC57774.2022.00025
- T. Bao, J. Yang, Y. Yang, and Y. Yin, “Rm2doc: a tool for automatic generation of requirements documents from requirements models,” in Proceedings of the ACM/IEEE 44th International Conference on Software Engineering: Companion Proceedings, 2022, pp. 188–192. [Online]. Available: https://doi.org/10.1145/3510454.3516850
- Y. Yang, Y. Liu, T. Bao, W. Wang, N. Niu, and Y. Yin, “Deepocl: A deep neural network for object constraint language generation from unrestricted nature language,” CAAI Transactions on Intelligence Technology, 2023. [Online]. Available: https://doi.org/10.1049/cit2.12207
- S. Reyal, S. E. Siriwardana, A. Kugathasan, S. Godage, D. Nissanka, S. Kalindu, and P. Uduwana, “An investigation into ui generation compliant with hci standards ensuring artifact consistency across sdlc,” in 2021 21st International Conference on Advances in ICT for Emerging Regions (ICter). IEEE, 2021, pp. 93–98. [Online]. Available: https://doi.org/10.1109/ICter53630.2021.9774787
- M. Ozkaya and F. Erata, “A survey on the practical use of uml for different software architecture viewpoints,” Information and Software Technology, vol. 121, p. 106275, 2020. [Online]. Available: https://doi.org/10.1016/j.infsof.2020.106275
- K.-F. Faxén, “A static semantics for haskell,” Journal of functional programming, vol. 12, no. 4-5, pp. 295–357, 2002. [Online]. Available: https://doi.org/10.1017/S0956796802004380
- S. Chang, A. Knauth, and B. Greenman, “Type systems as macros,” in Proceedings of the 44th ACM SIGPLAN Symposium on Principles of Programming Languages, 2017, pp. 694–705. [Online]. Available: https://doi.org/10.1145/3009837.3009886
- A brief overview of Agda–a functional language with dependent types. Springer, 2009.
- M. P. Papazoglou, P. Georgiadis, and D. G. Maritsas, “An outline of the programming language simula,” Computer languages, vol. 9, no. 2, pp. 107–131, 1984. [Online]. Available: https://doi.org/10.1016/0096-0551(84)90018-3
- “Rm2pt case studies,” accessed on 2024-01-12. [Online]. Available: https://github.com/RM2PT/CaseStudies
- A. Bove and P. Dybjer, “Dependent types at work,” in International LerNet ALFA Summer School on Language Engineering and Rigorous Software Development. Springer, 2008, pp. 57–99. [Online]. Available: https://doi.org/10.1007/978-3-642-03153-3_2
- RM2PT: A tool for automated prototype generation from requirements model. IEEE, 2019. [Online]. Available: https://doi.org/10.1109/ICSE-Companion.2019.00038
- V. Layka and D. Pollak, “Scala type system,” Beginning Scala, pp. 133–151, 2015, California, USA: Springer. [Online]. Available: https://doi.org/10.1007/978-1-4842-0232-6_8
- M. E. Conway, “Design of a separable transition-diagram compiler,” Communications of the ACM, vol. 6, no. 7, pp. 396–408, 1963. [Online]. Available: https://doi.org/10.1145/366663.366704
- B. Berthomieu, J.-P. Bodeveix, C. Chaudet, S. Dal Zilio, M. Filali, and F. Vernadat, “Formal verification of aadl specifications in the topcased environment,” in International Conference on Reliable Software Technologies. Springer, 2009, pp. 207–221. [Online]. Available: https://doi.org/10.1007/978-3-642-01924-1_15
- J. Kärnä, J.-P. Tolvanen, and S. Kelly, “Evaluating the use of domain-specific modeling in practice,” in Proceedings of the 9th OOPSLA workshop on Domain-Specific Modeling, 2009.
- R. F. Paige, D. S. Kolovos, and F. A. Polack, “A tutorial on metamodelling for grammar researchers,” Science of Computer Programming, vol. 96, pp. 396–416, 2014. [Online]. Available: https://doi.org/10.1016/j.scico.2014.05.007
- R. F. Paige, N. Matragkas, and L. M. Rose, “Evolving models in model-driven engineering: State-of-the-art and future challenges,” Journal of Systems and Software, vol. 111, pp. 272–280, 2016. [Online]. Available: https://doi.org/10.1016/j.jss.2015.08.047
- D. Distefano, J.-P. Katoen, and A. Rensink, “Towards model checking ocl,” in Proceedings of the ECOOP Workshop on Defining a Precise Semantics for UML, 2000.
- B. Combemale, X. Crégut, P.-L. Garoche, X. Thirioux, and F. Vernadat, “A property-driven approach to formal verification of process models,” in Enterprise Information Systems: 9th International Conference, ICEIS 2007, Funchal, Madeira, June 12-16, 2007, Revised Selected Papers 9. Springer, 2008, pp. 286–300. [Online]. Available: https://doi.org/10.1007/978-3-540-88710-2_23
- B. Berthomieu, P.-O. Ribet, and F. Vernadat, “The tool tina–construction of abstract state spaces for petri nets and time petri nets,” International journal of production research, vol. 42, no. 14, pp. 2741–2756, 2004. [Online]. Available: https://doi.org/10.1080/00207540412331312688
- V. Rusu, “Embedding domain-specific modelling languages in maude specifications,” ACM SIGSOFT Software Engineering Notes, vol. 36, no. 1, pp. 1–8, 2011. [Online]. Available: https://doi.org/10.1145/1921532.1921557
- B. Berthomieu, J.-P. Bodeveix, P. Farail, M. Filali, H. Garavel, P. Gaufillet, F. Lang, and F. Vernadat, “Fiacre: an intermediate language for model verification in the topcased environment,” in 4th European Congress ERTS Embedded Real Time Software (ERTS 2008), 2008, p. 8.
- K. Chauhan, S. Kumar, D. Sethia, and M. N. Alam, “Performance analysis of kotlin coroutines on android in a model-view-intent architecture pattern,” in 2021 2nd International Conference for Emerging Technology (INCET). IEEE, 2021, pp. 1–6. [Online]. Available: https://doi.org/10.1109/INCET51464.2021.9456197
- K. Chauhan, “Kotlin coroutines based mvi architecture library for android,” accessed on 2024-01-12. [Online]. Available: https://github.com/haroldadmin/Vector
- A. L. D. Moura and R. Ierusalimschy, “Revisiting coroutines,” ACM Transactions on Programming Languages and Systems (TOPLAS), vol. 31, no. 2, pp. 1–31, 2009. [Online]. Available: https://doi.org/10.1145/1462166.1462167
- M. Ikebuchi, A. Erbsen, and A. Chlipala, “Certifying derivation of state machines from coroutines,” Proceedings of the ACM on Programming Languages, vol. 6, no. POPL, pp. 1–31, 2022. [Online]. Available: https://doi.org/10.5281/zenodo.5628699
- A. Prokopec and F. Liu, “Theory and practice of coroutines with snapshots,” in 32nd European Conference on Object-Oriented Programming (ECOOP 2018). Schloss Dagstuhl-Leibniz-Zentrum fuer Informatik, 2018. [Online]. Available: https://doi.org/10.4230/LIPIcs.ECOOP.2018.3
- T. Górski, “The 1+ 5 architectural views model in designing blockchain and it system integration solutions,” Symmetry, vol. 13, no. 11, p. 2000, 2021. [Online]. Available: https://doi.org/10.3390/sym13112000
- R. L. Constable, “Type theory as a foundation for computer science,” in International Symposium on Theoretical Aspects of Computer Software. Springer, 1991, pp. 226–243. [Online]. Available: https://doi.org/10.1007/3-540-54415-1_48
- K. Weitz, G. Kim, S. Srisakaokul, and M. D. Ernst, “A type system for format strings,” in Proceedings of the 2014 International Symposium on Software Testing and Analysis, 2014, pp. 127–137. [Online]. Available: https://doi.org/10.1145/2610384.2610417
- E. Spishak, W. Dietl, and M. D. Ernst, “A type system for regular expressions,” in Proceedings of the 14th Workshop on Formal Techniques for Java-like Programs, 2012, pp. 20–26. [Online]. Available: https://doi.org/10.1145/2318202.2318207