Instructors: John Reekie and Christopher Hylands
Title: Tcl and Java Programming: Practice and Pitfalls
Intended Audience:
Tcl programmers interested in interfacing Tcl scripts to Java, and Java programmers interested in adding high-level scripting to their Java applications. Participants should already have some exposure to Tcl and the basic principles of object-oriented programming, and be confident enough to "pick up" new syntax as necessary.
Description:
Tcl Blend and Jacl are interfaces that allow Tcl scripts and Java classes to communicate. Tcl Blend uses the Java Native Interface and is written in C, while Jacl is a Tcl interpreter written in Java. This tutorial shows you how, when, and why to effectively use these interfaces. Topics covered include:
After completing this tutorial, participants will understand the strengths and weakness of the two interfaces and the relative strengths of Tcl and Java, and will have the knowledge to evaluate them for their own applications.
- Basics: an overview of Tcl Blend and Jacl, how to create and call Java objects from Tcl, and variable lifetime issues.
- Applications: writing Tcl extensions in Java, the Tcl JavaBean, Tcl test scripts for Java packages, adding Tcl front-ends to Java subsystems.
- Practical hints and tricks: using
System.out.println
, printing the Java stack trace from Tcl, exception handling, and so on.- Pitfalls : JDK1.2 issues, type system limitations, and problems using Jacl in applets.
Intending participants should visit the tutorial web page at
http://ptolemy.eecs.berkeley.edu/~johnr/tutorials/tcljava98/
. We will be making notes and examples available before the conference.About the Instructors:
John Reekie and Christopher Hylands are a post-doctoral researcher and the software manager for the Ptolemy Project at UC Berkeley. They are two of the principal authors of Tycho, a Tcl/Tk user interface for the Ptolemy simulator project, and are currently involved in the design and development of the Java version of Ptolemy. Christopher was also one of the primary outside testers of the Tcl Blend/Jacl release.