Automated Translation of Java Source Code to Eiffel

Reusability is an important software engineering concept actively advocated for the last forty years. While reusability has been addressed for systems implemented using the same programming language, it does not usually handle interoperability with different programming languages. This paper presents a solution for the reuse of Java code within Eiffel programs based on a source-to-source translation from Java to Eiffel. The paper focuses on the critical aspects of the translation and illustrates them by formal means. The translation is implemented in the freely available tool J2Eif; it provides Eiffel replacements for the components of the Java runtime environment, including Java Native Interface services and reflection mechanisms. Our experiments demonstrate the practical usability of the translation scheme and its implementation, and record the performance slow-down compared to custom-made Eiffel applications: automatic translations of java.util data structures, java.io services, and SWT applications can be re-used as Eiffel programs, with the same functionalities as their original Java implementations.

[1]  James R. Cordy,et al.  Source transformation, analysis and generation in TXL , 2006, PEPM '06.

[2]  Doris L. Carver,et al.  Reengineering legacy systems for distributed environments , 2002, J. Syst. Softw..

[3]  Doris L. Carver,et al.  Creating object-oriented designs from legacy FORTRAN code , 1997, J. Syst. Softw..

[4]  Harald C. Gall,et al.  Finding objects in procedural programs: an alternative approach , 1995, Proceedings of 2nd Working Conference on Reverse Engineering.

[5]  Clodoaldo Robledo,et al.  Google Web Toolkit , 2012 .

[6]  Lars Asplund Reliable Software Technologies — Ada-Europe , 1998, Lecture Notes in Computer Science.

[7]  Bertrand Meyer The Component Combinator for Enterprise Applications , 1998, J. Object Oriented Program..

[8]  K. Kontogiannis,et al.  Evidence driven object identification in procedural code , 1999, STEP '99. Proceedings Ninth International Workshop Software Technology and Engineering Practice.

[9]  Margot Postema,et al.  Reverse Engineering and Abstraction of Legacy Systems , 1998 .

[10]  Aniello Cimitile,et al.  A case study of applying an eclectic approach to identify objects in code , 1999, Proceedings Seventh International Workshop on Program Comprehension.

[11]  Heinz W. Schmidt,et al.  Reverse Engineering and Abstaction of Legacy Systems , 1998, Informatica.

[12]  Erwin Fielt,et al.  Scenarios for the identification of objects in legacy systems , 1997, Proceedings of the Fourth Working Conference on Reverse Engineering.

[13]  H. M. Sneed Migration of procedurally oriented COBOL programs in an object-oriented architecture , 1992, Proceedings Conference on Software Maintenance 1992.

[14]  D. R. Harris,et al.  Recovering abstract data types and object instances from a conventional procedural language , 1995, Proceedings of 2nd Working Conference on Reverse Engineering.

[15]  Giuseppe A. Di Lucca,et al.  Migrating legacy systems towards object-oriented platforms , 1997, 1997 Proceedings International Conference on Software Maintenance.

[16]  Peter Müller,et al.  Proof-transforming compilation of programs with abrupt termination , 2007, SAVCBS '07.

[17]  Gokul V. Subramaniam,et al.  Deriving an object model from legacy Fortran code , 1996, 1996 Proceedings of International Conference on Software Maintenance.

[18]  Gordon Kotik,et al.  Reengineering procedural into object-oriented systems , 1995, Proceedings of 2nd Working Conference on Reverse Engineering.

[19]  Darío Martín Nordio,et al.  Proofs and proof transformations for object-oriented programs , 2009 .

[20]  Richard Millham An investigation: reengineering sequential procedure-driven software into object-oriented event-driven software through UML diagrams , 2002, Proceedings 26th Annual International Computer Software and Applications.

[21]  Ying Zou,et al.  A framework for migrating procedural code to object-oriented platforms , 2001, Proceedings Eighth Asia-Pacific Software Engineering Conference.

[22]  Franklin Gracer,et al.  Saving a Legacy With Objects , 1989, OOPSLA.

[23]  Franklin Gracer,et al.  Saving a Legacy With Objects , 1989, OOPSLA.