Synthesis of interface specifications for Java classes

Rajeev Alur, P. Madhusudan, Pavol Černy, Wonhong Nam

Research output: Contribution to journalConference articlepeer-review

Abstract

While a typical software component has a clearly specified (static) interface in terms of the methods and the input/output types they support, information about the correct sequencing of method calls the client must invoke is usually undocumented. In this paper, we propose a novel solution for automatically extracting such temporal specifications for Java classes. Given a Java class, and a safety property such as "the exception E should not be raised", the corresponding (dynamic) interface is the most general way of invoking the methods in the class so that the safety property is not violated. Our synthesis method first constructs a symbolic representation of the finite state-transition system obtained from the class using predicate abstraction. Constructing the interface then corresponds to solving a partial-information two-player game on this symbolic graph. We present a sound approach to solve this computationally-hard problem approximately using algorithms for learning finite automata and symbolic model checking for branching-time logics. We describe an implementation of the proposed techniques in the tool JIST - Java Interface Synthesis Tool - and demon strate that the tool can construct interfaces accurately and efficiently for sample Java2SDK library classes.

Original languageEnglish (US)
Pages (from-to)98-109
Number of pages12
JournalConference Record of the Annual ACM Symposium on Principles of Programming Languages
DOIs
StatePublished - 2005
Externally publishedYes
EventPOPL 2005: The 32nd ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages - Long Beach, CA, United States
Duration: Jan 12 2005Jan 14 2005

Keywords

  • Abstraction
  • Behavioral interfaces
  • Games
  • Learning regular languages
  • Model checking
  • Software components
  • Synthesis

ASJC Scopus subject areas

  • Software

Fingerprint

Dive into the research topics of 'Synthesis of interface specifications for Java classes'. Together they form a unique fingerprint.

Cite this