Abstract
Model-driven software engineering (MDSE) provides a foundation for automatically generating software based on models that focus on the problem domain while abstracting from the details of underlying implementation platforms. Coloured Petri Nets (CPNs) have been widely used to formally model and verify protocol software, but limited work exists on using CPN models of protocols as a basis for automated code generation. The contribution of this paper is a method for generating protocol software from a class of CPN models annotated with code generation pragmatics. Our code generation method consists of three main steps: automatically adding so-called derived pragmatics to the CPN model, computing an abstract template tree, which associates pragmatics with code templates, and applying the templates to generate code which can then be compiled. We illustrate our method using a unidirectional data framing protocol.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Alanen, M., Lilius, J., Porres, I., Truscan, D.: On modeling techniques for supporting model driven development of protocol processing applications. In: Model-Driven Software Development, pp. 305–328. Springer (2005)
Baier, C., Katoen., J. -P.: Principles of Model Checking. MIT Press (2008)
Billington, J., Gallasch, G.E., Han, B.: A coloured Petri net approach to protocol verification. In: Desel, J., Reisig, W., Rozenberg, G. (eds.) ACPN 2003. LNCS, vol. 3098, pp. 210–290. Springer, Heidelberg (2004)
Brambilla, M., Cabot, J., Wimmer, M.: Model-Driven Software Engineering in Practice. Synthesis Lectures on Software Engineering. Morgan & Claypool Publishers (2012)
Budkowski, S., Dembinski, P.: An introduction to Estelle: A specification language for distributed systems. Computer Networks and ISDN Systems 14(1), 3–23 (1987)
Buse, R.P.L., Weimer, W.R.: A metric for software readability. In: Proc. of ISSTA 2008, pp. 121–130. ACM, NY (2008)
Choppy, C., Dedova, A., Evangelista, S., Hong, S., Klai, K., Petrucci, L.: The NEO Protocol for Large-Scale Distributed Database Systems: Modelling and Initial Verification. In: Lilius, J., Penczek, W. (eds.) PETRI NETS 2010. LNCS, vol. 6128, pp. 145–164. Springer, Heidelberg (2010)
Hannikainen, M., Knuutila, J., Hamalainen, T., Saarinen, J.: Using SDL for implementing a wireless medium access control protocol. In: Proc. International Symposium on Multimedia Software Engineering, pp. 229–236 (2000)
Jensen, K.: Coloured Petri nets and invariant methods. Theoretical Computer Science 14, 317–336 (1981)
Jensen, K., Kristensen, L.M.: Coloured Petri Nets - Modelling and Validation of Concurrent Systems. Springer (2009)
Kristensen, L.M., Mechlenborg, P., Zhang, L., Mitchell, B., Gallasch, G.E.: Model-based development of a course of action scheduling tool. International Journal on Software Tools for Technology Transfer 10, 5–14 (2008)
Simonsen, K.I.F., Kristensen, L.M.: Towards a CPN-based modelling approach for reconciling verification and implementation of protocol models. In: Machado, R.J., Maciel, R.S.P., Rubin, J., Botterweck, G. (eds.) MOMPES 2012. LNCS, vol. 7706, pp. 106–125. Springer, Heidelberg (2013)
Kristensen, L.M., Westergaard, M.: Automatic Structure-Based Code Generation from Coloured Petri Nets: A Proof of Concept. In: Kowalewski, S., Roveri, M. (eds.) FMICS 2010. LNCS, vol. 6371, pp. 215–230. Springer, Heidelberg (2010)
Kristensen, L.M., Simonsen, K.I.F.: Applications of Coloured Petri Nets for Functional Validation of Protocol Designs. In: Jensen, K., van der Aalst, W.M.P., Balbo, G., Koutny, M., Wolf, K. (eds.) ToPNoC VII. LNCS, vol. 7480, pp. 56–115. Springer, Heidelberg (2013)
Leduc, G., Germeau, F.: Verification of security protocols using LOTOS-method and application. Computer Communications 23(12), 1089–1103 (2000)
Mortensen, K.H.: Automatic code generation method based on coloured Petri net models applied on an access control system. In: Nielsen, M., Simpson, D. (eds.) ICATPN 2000. LNCS, vol. 1825, pp. 367–386. Springer, Heidelberg (2000)
Parssinen, J., von Knorring, N., Heinonen, J., Turunen, M.: In: Proc. TOOLS 2000, pp. 82–93 (2000)
PetriCode, Project Web Site, http://kentis.github.io/nppn-cli/
Philippi, S.: Automatic code generation from high-level Petri-nets for model driven systems engineering. Journal of Systems and Software 79(10), 1444–1455 (2006)
Pozza, D., Sisto, R., Durante, L.: Spi2Java: automatic cryptographic protocol Java code generation from spi calculus. In: Proc. of Advanced Information Networking and Applications, vol. 1, pp. 400–405 (2004)
Simonsen, K.I.F., Kristensen, L.M., Kindler, E.: Code generation for protocols from CPN models annotated with pragmatics – extended abstract. In: 24th Nordic Workshop on Programming Theory (November 2012)
Simonsen, K.I.F., Kristensen, L.M., Kindler, E.: Code Generation for Protocol Software from CPN models Annotated with Pragmatics. Technical Report IMM-Technical Reports-2013-01, Technical University of Denmark, DTU Informatics (January 2013), http://bit.ly/WwH2hf
Suzuki, I.: Formal analysis of the alternating bit protocol by temporal Petri nets. IEEE Transactions on Software Engineering 16(11), 1273–1281 (1990)
Wagstaff, K., Peters, K., Scharenbroich, L.: From protocol specification to statechart to implementation. Technical Report CL08-4014, Jet Propulsion Laboratory (2008)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2013 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Simonsen, K.I.F., Kristensen, L.M., Kindler, E. (2013). Generating Protocol Software from CPN Models Annotated with Pragmatics. In: Iyoda, J., de Moura, L. (eds) Formal Methods: Foundations and Applications. SBMF 2013. Lecture Notes in Computer Science, vol 8195. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-41071-0_16
Download citation
DOI: https://doi.org/10.1007/978-3-642-41071-0_16
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-41070-3
Online ISBN: 978-3-642-41071-0
eBook Packages: Computer ScienceComputer Science (R0)