A pattern-based approach to generate code from API usage scenarios

  • Authors:
  • Johannes Koskinen;Anna Ruokonen;Tarja Systä

  • Affiliations:
  • Institute of Software Systems, Tampere University of Technology, Tampere, Finland;Institute of Software Systems, Tampere University of Technology, Tampere, Finland;Institute of Software Systems, Tampere University of Technology, Tampere, Finland

  • Venue:
  • Nordic Journal of Computing - Selected papers of the fourth nordic workshop on UML and software modelling (NWUML'06), June 12-14, 2006
  • Year:
  • 2006

Quantified Score

Hi-index 0.01

Visualization

Abstract

The usage of an API of a software system requires learning and knowledge about the API itself. In tutorials, an API usage is typically described by giving a couple of example applications and some example code fragments. While such examples are useful and illustrative for the application developer, it is often difficult for her to separate application-specific parts from the API-specific ones, and further to distinguish optional and mandatory parts. In this paper we discuss an approach and tool support for guiding the application developer in API usage in a step-by-step fashion. As the examples are often sequential by their nature, we use UML sequence diagrams to describe possible API usage scenarios. We propose pattern-based tool support to exploit such sequence diagrams and to generate the application code in a semi-automated way.