01-11-2012, 01:36 PM
Java: Applications, Applets, & HTML
Java Applications.ppt (Size: 80.5 KB / Downloads: 27)
Updates & Corrections
Corrections
Academic Honesty Link (text) was wrong on Syllabus
Updates
Workshop #1 has be revised from Macintosh 4.x to NT Workstation 5.x
Java History
Initial motivation was for Embedded Systems
Control Devices & Processors
Expensive to develop software for these
Embedded Software
Software simulates the device
The Java Virtual Machine
Our program ‘runs’ on this simulation
The Browser
Advantages
Moves the burden of processing to the local machine
Reduces some server security concerns
Versions of Java
Version Numbering
Major.Minor.Revision
1.0.x Initial Release, about 1994
1.1.x First major Update, about 1997
Security & Event Handling
1.2.0 Second Release, November 1998
Security & more libraries
Also known as 2.0
Which one will we use?
The releases are currently 100% backward compatible.
Code written in 1.0 will work in 1.1 & 1.2
Produces compiler warnings (sometimes)
Code written in 1.1 or 2.0 environments using features found only in 1.0 will work in 1.0 environments
Use of 2.0 features will be identified
Browsing
A Browser is a Program
Running on a local machine
The Browser has a connection to a network
The network has a server that knows:
How to listen to the browser
How to find the files the browser asks for
Browser requests a file
The server finds the file and sends a copy to the browser (client)
The browser display the file according to the instructions within the file
The Power of the Browser
The Browser’s ability to interpret the file
Hyper Text Markup Language (HTML)
May simply contain text and format information
The course web pages
Content, format, color
May contain instructions to the browser
Links to other files
Load and execute a file
Executing Java files in the Browser
One of the instructions to the browser is to read and execute a file
The file is already in a special format
Very similar to an executable program file
Not associated with 'real' hardware
The browser reads the file
byte by byte
Interprets the general instructions as the appropriate actions on that platform
Applications Versus Applets
Applications
Stand alone programs
May read & write to local file system
Applets
Designed to run as a dependent program
Can’t read or write to local file system
Can’t execute other programs
May only communicate with downloading host