Java Reference
In-Depth Information
1.6 The Java Language Specification, API, JDK, and IDE
Java syntax is defined in the Java language specification, and the Java library is
defined in the Java API. The JDK is the software for developing and running Java
programs. An IDE is an integrated development environment for rapidly developing
programs.
Key
Point
Computer languages have strict rules of usage. If you do not follow the rules when writing a
program, the computer will not be able to understand it. The Java language specification and
the Java API define the Java standards.
The Java language specification is a technical definition of the Java programming lan-
guage's syntax and semantics. You can find the complete Java language specification at
java.sun.com/docs/books/jls .
The application program interface (API) , also known as library , contains predefined
classes and interfaces for developing Java programs. The API is still expanding. You can view
and download the latest version of the Java API at www.oracle.com/technetwork/java/index.html .
Java is a full-fledged and powerful language that can be used in many ways. It comes in
three editions:
Java language specification
API
library
Java Standard Edition (Java SE) to develop client-side standalone applications
or applets.
Java SE, EE, and ME
Java Enterprise Edition (Java EE) to develop server-side applications, such as Java
servlets, JavaServer Pages (JSP), and JavaServer Faces (JSF).
Java Micro Edition (Java ME) to develop applications for mobile devices, such as
cell phones.
This topic uses Java SE to introduce Java programming. Java SE is the foundation upon
which all other Java technology is based. There are many versions of Java SE. The latest,
Java SE 7, is used in this topic. Oracle releases each version with a Java Development Toolkit
(JDK). For Java SE 7, the Java Development Toolkit is called JDK 1.7 (also known as Java 7
or JDK 7 ).
The JDK consists of a set of separate programs, each invoked from a command line,
for developing and testing Java programs. Instead of using the JDK, you can use a Java devel-
opment tool (e.g., NetBeans, Eclipse, and TextPad)—software that provides an integrated
development environment (IDE) for developing Java programs quickly. Editing, compiling,
building, debugging, and online help are integrated in one graphical user interface. You simply
enter source code in one window or open an existing file in a window, and then click a button
or menu item or press a function key to compile and run the program.
Java Development Toolkit
(JDK)
JDK 1.7
=
JDK 7
Integrated development
environment
1.24
What is the Java language specification?
Check
1.25
Point
What does JDK stand for?
1.26
What does IDE stand for?
1.27
Are tools like NetBeans and Eclipse different languages from Java, or are they
dialects or extensions of Java?
1.7 A Simple Java Program
A Java program is executed from the main method in the class.
Key
Point
Let's begin with a simple Java program that displays the message Welcome to Java! on the
console. (The word console is an old computer term that refers to the text entry and display
device of a computer. Console input means to receive input from the keyboard, and console
output means to display output on the monitor.) The program is shown in Listing 1.1.
what is a console?
console input
console output
 
 
 
 
Search WWH ::




Custom Search