Automated translation of VDM to JML-annotated Java

被引:0
|
作者
Peter W. V. Tran-Jørgensen
Peter Gorm Larsen
Gary T. Leavens
机构
[1] Aarhus University,
[2] University of Central Florida,undefined
关键词
Design-by-Contract; Formal methods; VDM; Java; JML; Code-generation;
D O I
暂无
中图分类号
学科分类号
摘要
When a system specified using the Vienna Development Method (VDM) is realised using code-generation, no guarantees are currently made about the correctness of the generated code. In this paper, we improve code-generation of VDM models by taking contract-based elements such as invariants and pre- and postconditions into account during the code-generation process. The contract-based elements of the Vienna Development Method Specification Language (VDM-SL) are translated into corresponding constructs in the Java Modelling Language (JML) and used to validate the generated code against the properties of the VDM model. VDM-SL and JML are both Design-by-Contract (DbC) languages, with the difference that VDM-SL supports abstract modelling and system specification, while JML is used for detailed specification of Java classes and interfaces. We describe the semantic differences between the contract-based elements of VDM-SL and JML and formulate the translation as a set of rules. We further demonstrate how dynamic JML assertion checks can be used to ensure the consistency of VDM’s subtypes when a model is code-generated. The translator is fully automated and produces JML-annotated Java programs that can be checked for correctness using JML tools.
引用
下载
收藏
页码:211 / 235
页数:24
相关论文
共 50 条
  • [21] Beyond assertions: Advanced specification and verification with JML and ESC/Java']Java2
    Chalin, Patrice
    Kiniry, Joseph R.
    Leavens, Gary T.
    Poll, Erik
    FORMAL METHODS FOR COMPONENTS AND OBJECTS, 2006, 4111 : 342 - 363
  • [22] Formal specification of the Java']JavaCard API in JML: the APDU class
    Poll, E
    van den Berg, J
    Jacobs, B
    COMPUTER NETWORKS, 2001, 36 (04) : 407 - 421
  • [23] The Extension of Java']Java Annotated Concurrency Specification
    Liu Ruixiang
    Liu Wei
    Zhu Hong
    2009 INTERNATIONAL FORUM ON COMPUTER SCIENCE-TECHNOLOGY AND APPLICATIONS, VOL 1, PROCEEDINGS, 2009, : 448 - +
  • [24] Automated boundary test generation from JML specifications
    Bouquet, Fabrice
    Dadeau, Frederic
    Legeard, Bruno
    FM 2006: FORMAL METHODS, PROCEEDINGS, 2006, 4085 : 428 - 443
  • [25] Java']Java annotated concurrency based on the concurrent package
    Zhu, Hong
    Yin, Zhaolin
    Ding, Ying
    SEVENTH INTERNATIONAL CONFERENCE ON PARALLEL AND DISTRIBUTED COMPUTING, APPLICATIONS AND TECHNOLOGIES, PROCEEDINGS, 2006, : 38 - +
  • [26] AUTOMATIC TRANSLATION OF VDM SPECIFICATIONS INTO STANDARD ML PROGRAMS
    ONEILL, G
    COMPUTER JOURNAL, 1992, 35 (06): : 623 - 624
  • [27] A Verifier for Region-Annotated Java']Java Bytecodes
    Cherem, Sigmund
    Rugina, Radu
    ELECTRONIC NOTES IN THEORETICAL COMPUTER SCIENCE, 2005, 141 (01) : 183 - 201
  • [28] MASCOTime: Building a simulator with Java']Java for annotated MASCOT
    Sancho, PP
    Juiz, C
    SERP'03: PROCEEDINGS OF THE INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING RESEARCH AND PRACTICE, VOLS 1 AND 2, 2003, : 74 - 80
  • [29] Automated Refactorings in Java']Java
    Mahmood, Jeffrey
    Reddy, Y. Raghu
    SOUVENIR OF THE 2014 IEEE INTERNATIONAL ADVANCE COMPUTING CONFERENCE (IACC), 2014, : 1406 - 1414
  • [30] JMLAutoTest: A novel automated testing framework based on JML and knit
    Xu, GQ
    Yang, ZY
    FORMAL APPROACHES TO SOFTWARE TESTING, 2004, 2931 : 70 - 85