|
Characteristics
of Java
Java
was designed to have the 'look and feel'
of the C++ programming language, but is a lot simpler to use. Java-applets
are compiled in a byte-code that can be run on any server or client in a
network, which is equipped with a Java virtual machine (software which acts
as an interface between bytecode and platform-dependent microprocessor).
Java
follows an object-oriented approach, which means that, among other characteristics,
similar objects share common code, greatly reducing the amount of programming
code necessary to achieve similar effects at different locations or time
steps.
Java and JavaScript
For
special effects JavaScript is often used instead of Java. JavaScript is
an interpreted programming or script language from Netscape. It is somewhat
similar in capability to, for instance, Microsoft's Visual Basic. In general,
script languages are easier and faster to code than the more structured
and compiled languages such as C and C++ and are ideal for programs of
limited capability or that can reuse and tie together existing compiled
programs.
JavaScript
is used in Web site development to do such things as:
- automatically change a formatted date on a
Web page
- cause a linked page to appear in a popup window
- cause text or a graphic image to change during
a mouse over event
JavaScript uses some of the same ideas found in Java, the compiled object-oriented
language derived from C++. JavaScript code can be imbedded in HTML pages
and interpreted by the Web browser (or client). Current HTML-editors are
often capable of automatically generating the necessary JavaScript-code
for the most commonly used effects.
|
|