Java A very Hot ObjectOriented Language - PowerPoint PPT Presentation

1 / 13
About This Presentation
Title:

Java A very Hot ObjectOriented Language

Description:

( Java vs C /C) Why Java is HOT? Write Once, Run Anywhere model. ... Loader. What is New? Java Compilation, linking, loading & verifying & JVM: Java. Program ... – PowerPoint PPT presentation

Number of Views:35
Avg rating:3.0/5.0
Slides: 14
Provided by: johnc69
Category:

less

Transcript and Presenter's Notes

Title: Java A very Hot ObjectOriented Language


1
Java -- A very Hot Object-Oriented Language
Instructors Fu-Chiung Cheng (???) Associate
Professor Computer Science Engineering Tatung
Institute of Technology
2
Outline
  • Why Java is HOT?
  • What is Java?
  • What is New? (Java vs C/C)

3
Why Java is HOT?
  • Write Once, Run Anywhere model.
  • Network-Centric Computing (internet programming)
  • Interactive Content and Animation
    (multithreading)
  • support APIs for both client server
    applications
  • Near guarantee that you cant run a bad program.
  • WWW Java gives the world a new way to think.

4
What is Java?
  • Simple (compared to C)
  • Ture object-Orentied programming
  • Distributed
  • Robust
  • Secure
  • Archetectural Neutral
  • Multithreaded

5
What is New?
  • No global variables -- package.class.field
  • No preprocessor -- import statement
  • Unicode
  • No pointers
  • Garbage Collection
  • Array and String are first class objects
  • No goto statement
  • Single Inheritance
  • Java documentation generator
  • Applet with Web browsers

6
What is New?
  • Java documentation
  • Rich Libraries
  • A. 2D, 3D programming model
  • B. 2D animation API for video game
  • C. API for time-critical audio, vidio and MIDI
    data
  • D. Multithreading
  • E. Networking
  • F. Security
  • G. Exception handling
  • .

7
What is New?
  • C/C Compilation, linking loading

linker Loader
Binary File
Compiler
MAC
MAC
MAC
C Program
PC
PC
PC
Sun
Sun
Sun
8
What is New?
  • Java Compilation, linking, loading verifying
    JVM

Interpreter JVM
Compiler
MAC
MAC
Java Program
Java ByteCode
PC
PC
Sun
Sun
9
How Java Works?
Java Program
H A R D W A R E
Loader
Java Compiler
Verifier
Network or File System
Java ByteCode
JVM
10
Java Programs
  • Java standalone applications
  • Fully access your system resources (e.g.
    read/write files).
  • Java applets
  • No read/write access
  • Can not standalone,
  • Need browsers (appletviewer, Netscape, IE).

11
Java Standalone Applications
  • Public class HelloWeb
  • public static void main(String args)
  • System.out.println(Hello Web!)
  • Compilation
  • javac HelloWeb.java gt HelloWeb.class
  • Execution
  • java HelloWeb

12
Java Applets
Public class HelloWebApplet extend
java.applet.Applet public void
paint(java.awt.Graphs g) g.drawString(Hello
Web!, 125, 95) HTML lthtmlgt lth3gt Hello
Web Applet Example lt/h3gt ltapplet
codeHelloWebApplet width300
height200gt lt/appletgt lt/htmlgt
13
Conclusions
  • Java is a pure OO programming language
  • Cross-platform applications
  • (Write Once Run Anywhere)
  • WWW Java gives the world a new way to think.
Write a Comment
User Comments (0)
About PowerShow.com