Академический Документы
Профессиональный Документы
Культура Документы
Java - An Introduction
Java - The new programming language developed by Sun Microsystems in 1991. Originally called Oak by James Gosling, one of the inventors of the Java Language. Java -The name that survived a patent search Java Authors: James , Arthur Van , and others
debug
pretty portable
Java Compiler
Java Bytecode
Java Introduction
Originally created for consumer electronics (TV, VCR, Freeze, Washing Machine, Mobile Phone). Java - CPU Independent language Internet and Web was just emerging, so Sun turned it into a language of Internet Programming. It allows you to publish a web page with Java code in it.
Server
Java Milestones
Year 1990 Development Sun decided to developed special software that could be used for electronic devices. A project called Green Project created and head by James Gosling. Explored possibility of using C++, with some updates announced a new language named Oak The team demonstrated the application of their new language to control a list of home appliances using a hand held device.
1991
1992
1993
The World Wide Web appeared on the Internet and transformed the text-based interface to a graphical rich environment. The team developed Web applets (time programs) that could run on all types of computers connected to the Internet.
Java Milestones
Year 1994 Development The team developed a new Web browsed called Hot Java to locate and run Applets. HotJava gained instance success.
1995
Oak was renamed to Java, as it did not survive legal registration. Many companies such as Netscape and Microsoft announced their support for Java
1996
Java established itself it self as both 1. the language for Internet programming 2. a general purpose OO language.
1997-
A class libraries, Community effort and standardization, Enterprise Java, Clustering, etc..
10
Java 1.0
8 packages 212 classes
Java 1.1
23 packages 504 classes
Java 1.2
59 packages 1520 classes
Java 1.3
77 packages 1595 classes
Java 1.4
Java 1.5
103 packages 131 packages 2175 classes 2656 classes Regular Exp Logging Assertions NIO javax.activity, javax. management
CORBA
java.math, java.rmi, java.security, java.sql, java.text, java.beans java.applet, java.awt, java.io, java.lang, java.net, java.util
11
Simple Secure Portable Object - oriented Robust Multithreaded Architecture-neutral Distributed Interpreted Dynamic High performance
12
Object-orientation: Classes + Inheritance Distributed: RMI, Servlet, Distributed object programming. Robust: Strong typing + no pointer + garbage collection Secure: Type-safety + access control Architecture neutral: architecture neutral representation
13
Java byte code: Intermediate representation for Java programs Java compiler: Transform Java programs into Java byte code Java interpreter: Read programs written in Java byte code and execute them Java virtual machine: Runtime system that provides various services to running programs Java programming environment: Set of libraries that provide services such as GUI, data structures,etc. Java enabled browsers: Browsers that include a JVM + ability to load programs from remote hosts
14
C++
Java
15
No Typedefs, Defines, or Preprocessor No Global Variables No Pointers No Unsafe Structures No Multiple Inheritance No Operator Overloading No Automatic Coercions
16
javac - The Java Compiler java - The Java Interpreter jdb- The Java Debugger appletviewer -Tool to run the applets
javap - to print the Java bytecodes javaprof - Java profiler javadoc - documentation generator javah - creates C header files
17
javadoc
HTML Files
javac
javah
Header Files
java
jdb
Outout
18
Compile HelloWorld.java
javac HelloWorld.java
Output: HelloWorld.class
Run
java HelloWorld
20
Execution Platform
What is an execution platform? 1) An execution platform is the hardware or software environment in which a program runs, e.g. Windows 2000, Linux, Solaris or MacOS. 2) Most platforms can be described as a combination of the operating system and hardware.
21
22
23
24
25
26
Java API
What is Java API? 1) a large collection of ready-made software components that provide many useful capabilities, e.g. graphical user interface 2) grouped into libraries (packages) of related classes and interfaces 3) together with JVM insulates Java programs from the hardware and operating system variations
27
3) internationalization - programs that can be localized for users worldwide, automatically adapting to specific locales and appropriate languages.
29
30
Java Technologies
Different technologies depending on the target applications: 1) desktop applications - Java 2 Standard Edition (J2SE) 2) enterprise applications Java 2 Enterprise Edition (J2EE) 3) mobile applications Java 2 Mobile Edition (J2ME) 4) smart card applications JavaCard 5) etc. Each edition puts together a large collections of packages offeringfunctionality needed and relevant to a given application. The Java Virtual Machine remains essentially the same.
31
32