JAVA Development Environment
by Tracey Au-Yeung
27th May 1997
Introduction
In the first articles, we have discussed about
the features and the compiling techniques of Java, and now we are going
to look at the Java development environment.
What do we need for developing
in a Java environment ?
A platform-neutral, component architecture for
Java; for developing or assembling network-aware solutions for heterogeneous
hardware and operating system environments--within the enterprise or across
the Internet. With reliable and efficient compiler, development and debugging
tools. There are several choices across the market, and we are going to
look at the following:
-
JavaSoft's JavaBeans
-
Symantec's Cafe
-
Microsoft's Visual J++
-
IBM's VisualAge
JavaSoft's JavaBeans
What is a Bean ?
Some Beans are visual components that you add
to forms in visual-development tools; other Beans are faceless objects
that do something in the background. A Bean could be a cartoon or a piece
of business logic. You could build a simple Java applet by assembling a
bunch of Beans without doing any programming, or you could wrap some Beans
in thousands of lines of proprietary code to build a sophisticated
enterprise
application.
Throughout the industry, JavaBeans is the component
architecture of choice. Developing the dynamic data interchange
architecture.
One of the advantages of the JavaBeans architecture
is how easy is to instantiate Beans, be it inside another Bean, or in some
application or Applet. Beans are based on existing Java objects.
[1,2]
JavaBean's Features:
1. Introspection/reflection
A Bean can expose its data structures to other
programs and to programmers. For example, a development tool could have
an object inspector that lets a programmer examine a Bean's methods, instance
variables, properties, and interfaces.
2. A new event mechanism streamlines event handling
and works with AWT components.
Beans are just specialized Java class files.
In fact, all Abstract Windowing Toolkit [AWT] components are automatically
Beans, because AWT in JDK 1.1 adopts the new JavaBeans event model. Anybody
who has written a visual component that subclasses an AWT object has already
written a Bean.
Java still supports the existing handleEvents()
method for backward compatibility. Because the new model uses less indirection
and is more strongly typed, it's much more efficient, especially for high-frequency
events like mouse movements.
3. Serialization/persistence
Beans permanently remember changes to their properties.
Currently, objects always revert to their default
properties.
4. Interoperability
Beans work anyplace where ActiveX objects or
Live Objects can work.
(This is important, because a Beans developer
could then secures a future in the emerging network software market without
losing customers that use proprietary platform.)
You could also use a Bean with Visual Basic or
in an OpenDoc container such as ClarisWorks. The bridging technology does
practically all the work, so Bean authors have to write little or no code
to get OLE and OpenDoc compatibility. JavaSoft already has some existing
Java applets working with Visual Basic.
5. Beans are written in Java
Beans are prewritten software components that
make it easier to build Java programs. Software components that use JavaBeans
APIs are thus be portable to containers including Internet Explorer, Visual
Basic, Microsoft Word, Lotus Notes, etc.
6. Reusable software components
JavaBeans allows developers to create reusable
software components that can then be assembled together using visual application
builder tools, such as Borland's JBuilderTM, IBM's Visual AgeTM for Java,
SunSoft's Java WorkshopTM and Symantec's Visual Cafe, and others.
[3]
7. Cross-platform
Beans are platform-neutral, JavaBeans extends
Java's "Write Once, Run Anywhere" SM capability to reusable component development,
and your code can run on every OS and also within any application environment.
[4]
8. Speed up Java's evolution
Third parties can create Beans that fill some
of the gaps in Java's capabilities.
Symantec's Cafe
It is a standalone, Java development environment
tool mainly for Macintosh, but also available for Windows NT/95.
Symantec Café is based on the Symantec
Project Manager development environment, and has been designed to provide
Java development capabilities, which lets you create Java applets and applications
that run on Macintosh, Windows, and UNIX systems.
Café's intuitive graphical interface makes
creating Java Applets easy. Applets built with
Symantec Café can be embedded into HTML
documents to provide dynamic functionality on multiple platforms (Macintosh,
Windows, Unix) when using a Java enabled web browser such as Netscape's
Navigator, or with your corporate Intranet.
For web page designers, Café includes an
"Intro to Java Programming" tutorial, Java language reference, Café
Studio visual tools for graphically drawing Java applets on screen and
having the corresponding source code generated automatically, and over
90 sample applets that can be easily modified to create your own custom
applets.
For professionals familiar with programming, Café
provides an unrivaled feature set, including an integrated graphical class
browser, fast native Java compiler, a full-featured project manager, a
professional Java source code editor, and full support for AppleScript
and AppleEvents for automating time consuming tasks.
[5]
Symantec Café Key Features:
1. A Head-Start on Java Development
Easy-to-use: It provides the "Intro to
Java Programming" tutorial, AppleGuide, Café Guide and Sample Applets
to teach beginners the Java programming, the usage of the Café development
environment and the method of creating your own Java applets.
Café Studio Visual Tools: Create
your Java-based forms and applet on screen visually and Café Studio
automatically generates the corresponding Java source code, it rapidly
create demos and prototypes of Applets and then use the corresponding results
in the actual applet you are developing. You do this by simply drawing
your applet on screen and assigning different commands to it. You can draw
text labels and fields, buttons, check boxes, radio buttons, pop-up menus,
scroll bars, and lists and have Café Studio then automatically generates
the corresponding Java source code for you. With the object alignment,
snap to grid capabilities, and control over font, size, and style of text
creating good-looking Java applets is easy.
2. Highly Productive Environment
Graphical Class Hierarchy: Café
gives you a graphical view of the Java class hierarchy
creates a repository of information about the
Java applet and class libraries. This provides a visual representation
of the Java application class hierarchy, allowing you to better understand
the standard Java classes and your application's classes.
Easy Access to Documentation: Double click
on a class file in the browser and Café
automatically launches the corresponding HTML
documentation in your favorite web browser.
Fast Symantec Bytecode Compiler: Café
includes a bytecode Java compiler that compiles several times faster than
the standard Sun Java compiler.
Integrated Environment: Café seamlessly
integrates the Sun Java Development Kit (JDK) tools into the development
environment with graphical support for the Java compiler, interpreter and
debugger options and parameters.
Integrated Debugger: Monitor object values;
display nested values; represent integers in decimal, hex, unsigned and
unicode; set breakpoints in any open source file.
Native JavaDoc: Generates HTML documents
from Java source code with JavaDoc now integrated into the Symantec Java
Compiler.
3. Full-Featured Project Manager
It offers multiple open projects at a time and
nested subfolders let you develop and maintain even the most complex Java
applications.
Project Support: Different project targets
can be managed through the Symantec Project Manager (SPM), without having
to load and unload projects one-by-one. SPM supports multiple open projects,
and drag and drop entire projects to external applications. SPM also keeps
track of the recently used applets for easy access.
Nested Sub-folders: You can structure,
organize, and manage your web projects and applets quickly and easily.
4. Powerful Class Editor
Integrated Graphical Class Browser: It
allows you to open multiple customizable graphical and SmallTalk-style
browsers. Instantaneous access to object oriented code allows you to work
with Java at a higher level than the source file views. The class browser
allows you to have multiple panes and orientations (horizontal and vertical),
and allows you to display, browse and edit methods, files, classes, data,
functions; and source code in alphabetical, hierarchical, and graphical
views.
Productivity-Boosting Features: Café
provides a professional programmer's editor for Java development with multiple
split panes, drag and drop text editing, and full color syntax and keyword
highlighting. The SPM environment also lets you plug in third party editors
such as BBEdit if you want to use them instead of the SPM editor.
Hierarchy editor: it lets you to view and
edit the Java class hierarchy.
5. More
Café is fully scriptable and recordable,
letting you automate routine tasks and save time using AppleScript. Its
integrated graphical debugger helps you efficiently debug your applications
at the source level, browse data, and manipulate threads. Café also
includes extensive on-line support, help and documentation.
System Requirements:
For Macintosh:
[6]
-
Power Macintosh, 68030, or 68040 Macintosh (030 processor
or greater)
-
MacOS 7.5
-
20 MB RAM minimum
-
40 - 70 MB free hard disk space (depending on installation
options)
-
CD-ROM drive for installation
For Window 95/NT:
[7]
-
Intel 386 or above
-
8MB RAM minimum, 16 MB RAM recommended for large
projects
-
Disk Space: 20-30 MB depending on configuration
-
Windows 95 or Windows NT
-
VGA (Super VGA recommended)
-
CD-ROM drive
Microsoft's Visual J++
Visual J++ is another development
environment for writing Java applets and applications. Visual J++ provides
a progressive shift for the Java language. It's Java plus Component Object
Model (COM). The Visual J++ compiler and Type Library Wizard allow Java
programs to access language-independent COM libraries and controls.
Visual J++ is Microsoft's visual Java development
environment. Using the same innovative user interface found in Microsoft
Visual C++; where Visual J++ includes:
-
A visual debugger.
-
Wizards to build applets and ActiveX controls.
-
A class viewer for easier comprehension of Java objects.
-
An advanced editor with syntax highlighting.
-
A source code compiler which translates at a rate
over 10,000 lines per second.
-
An online tutorial.
-
The Microsoft Press book, Learn Java Now.
-
Internet Explorer 3.0 with Java support and redistribution
rights.
-
An advanced JIT compiler for the fastest applet execution.
-
Java Class Hierarchy chart.
Visual J++ is certified as Java Compatible and allows
users to build cross-platform applications, with specific optimization
for the most common environments, such as Microsoft's Windows 95 and Windows
NT, without affecting portability.
Visual J++'s features:
1. Cross-platform
Build 100% Java-compatible, cross-platform applets
and applications, or extend them to integrate with your existing applications
so that you can leverage your existing skills and code. Visual J++ creates
100% Java-compatible code that runs on every platform that supports a Java
virtual machine (including Win95, Win/NT, Solaris, Macintosh and others).
Applications built with Visual J++ will work with
any major browser, including Internet Explorer 3.0 and Netscape Navigator.
Microsoft has fully embraced the Java language and is making it even more
powerful by allowing Java to easily integrate with existing applications
and databases.
2. Easy-to-use
Wizards to provide visual instructions for creating
applets. Interactive help and online tutorial. Complete online documentation
that includes the full Java API and language specifications from Sun Microsystems,
customizable, context-sensitive help and extensive sample code.
A familiar look and feel to other Microsoft development
products, such as Microsoft Visual C++ because Visual J++ uses the same
development environment A large selection of Java samples. Full compliance
with all Java standards.
3. Visually create Java forms:
The resource editor allows you to visual layout
the interface of your application. The editor is the same one that is used
in VC++, so there is very little learning for a lot of people. In addition,
there is a resource editor that lets you convert existing VisualBasic and
VisualC++ forms into cross-platform Java code. This helps create efficient
programs, and customers will like this familiar interface.
4. Debugger.
To quickly resolve application problems, a graphical
debugger is an essential part of a programming language. Visual J++ offers:
-
Debugging multiple applets running simultaneously
within the target browser.
-
Bytecode disassembly.
-
Bytecode level stepping and tracing.
-
Assigning values to variables.
-
DataTips to allow developers to get the value of
a variable or a highlighted expression during testing.
-
AutoTab, an expandable tree control to show expressions
of interest around a program counter.
-
Complex type expansion in a variables window, using
an expandable tree control format.
-
Highlighting changes made in all appropriate windows.
-
Stepping out of nested levels during debugging.
-
Debugging code without source-line information.
-
Stopping debugging at any time while target process
is running.
-
Setting breakpoints at any time while target process
is running.
-
Showing parameters in call stack.
-
Evaluating arbitrary or complex expressions.
-
Debugging Component Object Model (COM) objects written
in Java.
Visual J++ has a wizard that reads the type libraries
of COM objects (including ActiveX controls) that you choose to import.
This is what lets you easily use the methods and properties of the COM
object as if they were simply other Java classes.
5. Java source code compiler
The Visual J++ compiler does everything that
the other compilers do, plus it allows for ActiveX integration and has
unparalleled compilation speed. The Visual J++ compiler is currently compiling
over 10,000 lines of code a second.
The Visual J++ compiler is part of the Java development
tool, which is not the same as a JIT compiler. The Visual J++ compiles
Java source code into bytecode. The JIT (Just-In-Time) compiler is part
of the Java Virtual Machine. It accelerates the run-time performance of
your Java code. Visual J++ includes a JIT compiler which is freely distributable.
6. More Tools provide
comprehensive functionality
Visual J++ is a Windows-based tool to the character-based
Sun Microsystems Java Development Kit (JDK). Visual J++ also includes:
-
Class Viewer: it helps you to understand the
relationship between Java classes, methods, and properties.
-
Resource Editor: it provides the ability to
paint forms and menus or import existing forms developed with other Microsoft
products, such as Visual C++.
-
Database Wizard: it develops high-performance
database access via DAO and RDO using the Database Wizard.
-
Just-in-Time compiler: it distributables free
copies of Internet Explorer 3.0 with the most efficient Just-in-Time (JIT)
applet compiler for easiest and fastest end-user navigation over the Internet
or intranet.
-
Support for ActiveX controls to leverage your existing
investment in desktop applications and easily add efficient, interactive
content.
System Requirements
Visual J++ requires Windows 95 or Windows NT
4.0 for development only. The Java code that it creates, however, runs
on any platform that has a Java Virtual Machine.
-
PC 486, Windows 95/NT
-
8 MB of memory
-
Hard-disk space:
-
Typical installation: 43 MB
-
Minimum installation: 33 MB
-
Total tools and information on compact disc: 50 MB
-
CD-ROM drive
-
VGA or higher-resolution monitor (Super VGA recommended)
-
Microsoft Mouse or compatible pointing device
[8]
IBM's VisualAge
IBM VisualAge for Java is the first enterprise
aware, team enabled, incremental application development environment in
the industry. It is designed to connect Java clients to existing server
data, transactions and applications. This enables developers to extend
server-based applications to communicate with Java clients on the Internet
or intranet, rather than rewrite the application from scratch. VisualAge
for Java creates 100% Pure Java compatible applications, applets and JavaBeans.
However, this technology is not ready for prime
time, with numerous beta-code glitches and a documented warning that the
beta version's generated code may not work with other Java virtual machines
or with future versions of the IBM product.
[9]
VisualAge beta-version's Features
VisualAge for Java is designed to run on
Windows 95, Windows NT, and OS/2 Merlin. Versions for AIX and other Unix
platforms will follow. All versions will create both applets and applications
and include an applet viewer and the Java Virtual Machine (JVM) so you
can test either type of code. Of course, because VA for Java will be a
Java development tool, the target system can be any system that supports
the JVM, including RISC-based AS/400s.
[10]
1. Visual Builder
It lets you visually create a graphical interface
by selecting icons for visual components and arranging them on an application
window. Drag and Drop features just like Symentec Cafe and Miscosoft J++,
allow you to draw a connection between the grid in the application
window and the nonvisual part. The connection automatically causes the
list of items to be updated when the user edits the contents of the grid.
You need not write any code to detect changes to the display or update
the program variable that holds the list of items.
Creating classes from scratch is fairly easy in
Java, and VA for Java will have a SmartGuide to generate the required code
to start a new class definition.
2. Data Access Builder
VA for Java has a Data Access Builder for accessing
database files, easily import and export files in standard format from
IBM's repository.
VA for Java also will include support for making
connections between parts that represent a database file (or record) and
visual parts, such as a grid.
3. More Tools
Class browser let you display the definition
of a class or method you're working with or browse lists of packages (groups
of classes), classes, and methods to find the one you need.
VisualAge for Java will provide a powerful debugger.
VA for Java's will display source code while your application runs.
Automatic Versioning that VisualAge for Java,
performs during incremental development, making it easy to go back to a
working version of one's code. The environment's automatic incremental
compilation made Java feel more like an interpreted language by giving
immediate notification of coding errors.
IBM's Jikes
compiler for Java 1.1, although is not a visual tool, it shows that the
company thoroughly understands this technology. In PC Week Labs' tests,
Jikes identified Java source code flaws such as unreachable statements
that were ignored, for example, by Sun's Version 1.1 javac compiler.
[11]
4. Creating Client/Server Applications
Java has an elegant mechanism for making procedure
calls from an application running on one system to some code that executes
on another system. VisualAge for Java will make the whole process even
easier because an application will develop as if it were all local and
use a tool known as the Proxy Builder to partition the application and
automatically generate the necessary pieces to support the stub and skeleton
objects.
Conclusion
Java is an exciting new application programming
language designed by Sun Microsystems for the development of cross-platform
applets and applications for the world-wide web. Simply put Java applets
can provide interactive and dynamic behavior which could found in HTML-based
web pages. Java can make web pages come alive and make them significantly
more compelling.
More than 400,000 developers around the world
have already embraced the Java platform. Java has opened up an entirely
new world of opportunities for building fully portable network-aware applications.
Java's strong language features are complemented by the rich Integrated
Development Environments (IDEs) offered by several major vendors. And all
the Java Development Environment describe above are aimed to provide a
user-friendly and efficient environment for developers to build their own
Java applets and applications.
However, it is difficult to say which development
environment is better, it depends on the developer's need and personnal
preference.
Here is a comparison of the
Symantec Cafe 1.5 and Microsoft's J++,
and an eariler one on
SunSoft's Java Workshop 1.0 and Symantec Cafe 1.2.
Reference
1.
JavaBeans Hot News
by Sun JavaSoft
2.
JavaBeans Advisor
by Sun JavaSoft (Issue#4 30 Apr$
3.
Development Tools for JavaBeans
by Sun JavaSoft
4.
JavaBeans: Cross-Platform Components
by Byte Magazine (May 1997)
5.
Cafe for Macintosh Fact Sheet
by Symantec (March 1997)
6.
Cafe for Machintosh
by Symantec (March 1997)
7.
Cafe for Window 95/NT
by Symantec (February 1997)
8.
Visual J Web Page
by Microsoft (May 1997)
9.
IBM VisualAge for Java
by IBM
10.
Inside IBM's VisualAge for Java
by Paul Contte (April 1997)
11.
IBM, Netscape raise Web ante
by Peter Coffee in PC Week (April 1997)
12.
Symantec Cafe vs Microsoft J++
by Symantec (January 1997)
13.
SunSoft Java Workshop vs Symantec Cafe
by PC Computing