Java Reference
In-Depth Information
embeddedapplicationsknownas applets .Youareintroducedtostandaloneap-
plicationslaterinthissection.Idon'tdiscussappletsbecausetheyaren'taspop-
ular as they once were.
• The Java ME (Mobile Edition) SDK is used to create applications known as
MIDletsandXlets. MIDlets targetmobiledevices,whichhavesmallgraphical
displays, simple numeric keypad interfaces, and limited HTTP-based network
access. Xlets typically target television-oriented devices such as Blu-ray Disc
players.TheJavaMESDKrequiresthattheJDKalsobeinstalled.Idon'tdis-
cuss MIDlets or Xlets.
• TheJavaEE(EnterpriseEdition)SDKisusedtocreatecomponent-basedenter-
priseapplications.Componentsinclude servlets ,whichcanbethoughtofasthe
server equivalent of applets, and servlet-based Java Server Pages (JSPs). The
Java EE SDK requires that the JDK also be installed. I don't discuss servlets.
ThissectionintroducesyoutoJDK7(alsoreferredtoas Java 7 ,atermusedinlater
chapters) by first showing you how to install this latest major Java SE release. It then
showsyouhowtouseJDK7toolstodevelopasimplestandaloneapplication—I'lluse
the shorter application term from now on.
Installing JDK 7
Point your browser to http://www.oracle.com/technetwork/java/
javase/downloads/index-jsp-138363.html andfollowtheinstructionson
theresultingwebpagetodownloadtheappropriateJDK7installationexeorgziptarball
file for your Windows, Solaris, or Linux platform.
Followingthedownload,runtheWindowsexecutableorunarchivetheSolaris/Linux
gzip tarball, and modify your PATH environment variable to include the resulting
home directory's bin subdirectory so that you can run JDK 7 tools from anywhere
in your filesystem. For example, you might include the C:\Program
Files\Java\jdk1.7.0 homedirectoryinthe PATH onaWindowsplatform.You
should also update your JAVA_HOME environment variable to point to JDK 7's home
directory, to ensure that any Java-dependent software can find this directory.
JDK7'shomedirectorycontainsseveralfiles(e.g., README.html and LICENSE )
and subdirectories. The most important subdirectory from this topic's perspective is
bin , which contains various tools that we'll use throughout this topic. The following
list identifies some of these tools:
jar :atoolforpackagingclassfilesandresourcefilesintospecialZIPfileswith
.jar ” file extensions
Search WWH ::




Custom Search