کد مقاله | کد نشریه | سال انتشار | مقاله انگلیسی | نسخه تمام متن |
---|---|---|---|---|
433336 | 1441666 | 2014 | 17 صفحه PDF | دانلود رایگان |

• We identify and solve problems imposed by Java and Smalltalk integration.
• STX:LIBJAVA, a JVM implementation built into Smalltalk/X is presented.
• Interoperability features of STX:LIBJAVA (e.g. dynamic proxy methods) are shown.
• We validated our implementation on various Java projects, e.g. Groovy or Tomcat.
• Performance comparation of Oracle JVM and STX:LIBJAVA is provided.
After decades of development in programming languages and programming environments, Smalltalk is still one of few environments that provide advanced features and is used in the industry. However, as Java became prevalent, the ability to call a Java code from Smalltalk became important. A traditional approach to integrate the Java and Smalltalk languages is through low-level communication between separate Java and Smalltalk virtual machines. To our best knowledge there is no other project attempting to execute and integrate the Java language directly in the Smalltalk environment. A direct integration allows for a very tight integration of the languages and their objects within a single environment. Yet integration and language interoperability impose challenging issues related to method naming conventions, method overloading, exception handling and thread-locking mechanisms.In this paper we describe ways to overcome these challenges and to integrate Java into the Smalltalk environment. We focus on a possibility to call a Java code from Smalltalk using standard Smalltalk idioms while the semantics of both languages remains preserved. We present stx:libjava – an implementation of a Java virtual machine within Smalltalk/X – as a validation of our approach.
Journal: Science of Computer Programming - Volume 96, Part 1, 15 December 2014, Pages 17–33