JOURNAL ARTICLE

UML state machine diagram driven runtime verification of Java programs for message interaction consistency

Abstract

In object-oriented programs, we often need to set some restrictions on the temporal orders of the message receiving for objects, which forms a class of safety requirements. In this paper, we use UML state machine diagrams as design specifications, and present an approach to runtime verification of Java programs, which is focused on the temporal order of message receiving based consistency verification between the behavior of state machine diagrams and the program execution traces. In the approach, we first instrument the program under verification so as to gather the program execution traces related to a given state machine diagram. Then we drive the instrumented program by random test cases so as to generate the program execution traces. Finally we check if the collected program execution traces are consistent with the behavior of the state machine diagram, which means that the temporal orders of the message receiving occurring in the program traces are consistent with the ones occurring in the state machine diagram. Our approach can be used to detect not only the program bugs resulting from the wrong temporal orders of message receiving, but also the imperfect state machine models constructed in reverse engineering for legacy systems, and leads to a testing tool which may proceed in a fully automatic fashion.

Keywords:
Computer science State diagram Programming language Java Consistency (knowledge bases) Finite-state machine State (computer science) Abstract state machines Activity diagram Runtime verification Unified Modeling Language Set (abstract data type) Communication diagram Sequence diagram Class diagram Formal verification Software Artificial intelligence

Metrics

7
Cited By
1.58
FWCI (Field Weighted Citation Impact)
22
Refs
0.87
Citation Normalized Percentile
Is in top 1%
Is in top 10%

Citation History

Topics

Software Testing and Debugging Techniques
Physical Sciences →  Computer Science →  Software
Software Reliability and Analysis Research
Physical Sciences →  Computer Science →  Software
Software Engineering Research
Physical Sciences →  Computer Science →  Information Systems

Related Documents

JOURNAL ARTICLE

Predictive Runtime Verification of Java Programs

Kang YuZhen Bang ChenWei Dong

Journal:   Advanced materials research Year: 2014 Vol: 1078 Pages: 333-336
JOURNAL ARTICLE

Event-based runtime verification of java programs

Marcelo d’AmorimKlaus Havelund

Journal:   ACM SIGSOFT Software Engineering Notes Year: 2005 Vol: 30 (4)Pages: 1-7
JOURNAL ARTICLE

Specification and Runtime Verification of Java Card Programs

Umberto Souza da CostaAnamaria Martins MoreiraMartín A. MusicantePlácido A. Souza Neto

Journal:   Electronic Notes in Theoretical Computer Science Year: 2009 Vol: 240 Pages: 61-78
© 2026 ScienceGate Book Chapters — All rights reserved.