What Is The Use Of Java Development Kit

WHAT IS JAVA DEVELOPMENT KIT

The Java Development Kit is a distribution of Java Technology by Oracle Corporation. It implements the Java Language Specification and the Java Virtual Machine Specification and provides the Standard Edition of the Java Application Programming Interface.

The Java Development Kit (JDK) is a software development environment used for developing Java applications and applets.

It includes the Java Runtime Environment (JRE), an interpreter/loader (java), a compiler (javac), an archiver (jar), a documentation generator (javadoc) and other tools needed in Java development.

The Java Development Kit (JDK) is one of three core technology packages used in Java programming, along with the JVM (Java Virtual Machine) and the JRE (Java Runtime Environment). It’s important to differentiate between these three technologies, as well as understanding how they’re connected:

  • The JVM is the Java platform component that executes programs.
  • The JRE is the on-disk part of Java that creates the JVM.
  • The JDK allows developers to create Java programs that can be executed and run by the JVM and JRE.

Developers new to Java often confuse the Java Development Kit and the Java Runtime Environment. The distinction is that the JDK is a package of tools for developing Java-based software, whereas the JRE is a package of tools for running Java code.

The JRE can be used as a standalone component to simply run Java programs, but it’s also part of the JDK. The JDK requires a JRE because running Java programs is part of developing them.

Figure 1 shows how the JDK fits into the Java application development lifecycle.3e578348 d5c1 42e9 be50 b12b6a7b80fdhttps://imasdk.googleapis.com/js/core/bridge3.502.0_en.html#goog_14349366202 seconds of 28 secondsVolume 0% 

jw whatisjdk fig1
Figure 1. High-level view of the JDK

Let’s consider the technical and everyday definitions of the JDK:

  • Technical definition: The JDK is an implementation of the Java platform specification, including compiler and class libraries.
  • Everyday definition: The JDK is a software package you download in order to create Java-based applications.

The JDK & the Java compiler

In addition to the JRE, which is the environment used to run Java applications, every JDK contains a Java compiler. The compiler is the software program capable of taking raw .java files–which are plain text–and rendering them into executable .class files. We’ll see the compiler in action soon. First, I’ll show you how to download and setup a JDK in your development environment.

As a major programming language throughout the past few decades, Java has been integral to computer science, and the Java JDK is the essential vehicle for establishing a development environment.

People new to Java may be confused about whether to use the JRE or the JDK. To run Java applications and applets, simply download the JRE. However, to develop Java applications and applets as well as run them, the JDK is needed. One way to think of it is that JRE is “just for executables” or limited to that scope, where the JDK is the development toolkit, as mentioned.

Java developers are initially presented with two JDK tools, java and javac. Both are run from the command prompt. Java source files are simple text files saved with an extension of .java. After writing and saving Java source code, the javac compiler is invoked to create .class files. Once the .class files are created, the ‘java’ command can be used to run the java program.

For developers who wish to work in an integrated development environment (IDE), a JDK bundled with Netbeans can be downloaded from the Oracle website. Such IDEs speed up the development process by introducing point-and-click and drag-and-drop features for creating an application.

There are different JDKs for various platforms. The supported platforms include Windows, Linux and Solaris. Mac users need a different software development kit, which includes adaptations of some tools found in the JDK.

The Use of IDEs

As with other kinds of specific language development environments, programmers and engineers can use the Java development kit in an IDE for enhanced support.

However, JDK does stand on its own somewhat uniquely, as one of the biggest pushes for IDE use in some other cases is that it centralizes a toolkit.

Since JDK already includes the Java Runtime Environment, an interpreter, compiler, archiver and document generator, it’s hard to say that the IDE centralizes tools much more than that.

However, experts still say that the IDE provides an enhanced environment and, as mentioned above, speeds up or automates some of the processes of using JDK. The use of a graphical user interface to abstract and guide a user’s progress in development has been a signature advance of the past years as engineers found shortcuts beyond just using “hand coding” methods.

In the above example of bundling JDK with NetBeans, the IDE involves creating this kind of an overlay for the essential JDK that’s still necessary to work on these creations. Think about having the most commonly used controls visualized and optimized for access. This is the kind of operational benefit that the IDE tends to provide over strictly sticking with the JDK.

JDK Tools and Utilities

Basic Tools

These tools are the foundation of the JDK. They are the tools you use to create and build applications.

Tool NameBrief Description
appletviewerRun and debug applets without a web browser.
aptAnnotation processing tool.
extcheckUtility to detect Jar conflicts.
jarCreate and manage Java Archive (JAR) files.
javaThe launcher for Java applications. In this release, a single launcher is used both for development and deployment.
The old deployment launcher, jre, is no longer provided.
javacThe compiler for the Java programming language.
javadocAPI documentation generator.
javahC header and stub generator. Used to write native methods.
javapClass file disassembler
jdbThe Java Debugger.

Security Tools

These security tools help you set security policies on your system and create applications that can work within the scope of security policies set at remote sites.

Tool NameBrief Description
keytoolManage keystores and certificates.
jarsignerGenerate and verify JAR signatures.
policytoolGUI tool for managing policy files.

These security tools help you obtain, list, and manage Kerberos tickets.

Tool NameBrief Description
kinitTool for obtaining Kerberos v5 tickets. Equivalent functionality is available on the Solaris operating system via the kinit tool. For example, for Solaris 11,
klistCommand-line tool to list entries in credential cache and key tab. Equivalent functionality is available on the Solaris operating system via the klist tool. For example, for Solaris 11, the
ktabCommand-line tool to help the user manage entries in the key table. Equivalent functionality is available on the Solaris operating system via the kadmin tool. For example, for Solaris 11,

Internationalization Tools

This tool helps to create localizable applications.

Tool NameBrief DescriptionLinks to Reference Pages
native2asciiConvert text to Unicode Latin-1.

Remote Method Invocation (RMI) Tools

These tools help to create applications that interact over the Web or other network.

Tool NameBrief Description
rmicGenerate stubs and skeletons for remote objects.
rmiregistryRemote object registry service.
rmidRMI activation system daemon.
serialverReturn class serialVersionUID.

Java IDL and RMI-IIOP Tools

These tools are used when creating applications that use OMG-standard IDL and CORBA/IIOP.

Tool NameBrief Description
tnameservProvides access to the naming service.
idljGenerates .java files that map an OMG IDL interface and enable an application written in the Java programming language to use CORBA functionality.
orbdProvides support for clients to transparently locate and invoke persistent objects on servers in the CORBA environment. ORBD is used instead of the Transient Naming Service, tnameserv. ORBD includes both a Transient Naming Service and a Persistent Naming Service. The orbd tool incorporates the functionality of a Server Manager, an Interoperable Naming Service, and a Bootstrap Name Server. When used in conjunction with the servertool, the Server Manager locates, registers, and activates a server when a client wants to access the server.
servertoolProvides ease-of-use interface for the application programmers to register, unregister, startup, and shutdown a server.

Java Deployment Tools

Utilities for use in conjunction with deployment of java applications and applets on the web.

Tool NameBrief Description
javafxpackagerPackages JavaFX applications for deployment.
pack200Transforms a JAR file into a compressed pack200 file using the Java gzip compressor. The compressed packed files are highly compressed JARs, which can be directly deployed, saving bandwidth and reducing download time.
unpack200Transforms a packed file produced by pack200 into a JAR file.

Java Web Start Tools

Utilities for use in conjunction with Java Web Start.

Tool NameBrief Description
javawsCommand line tool for launching Java Web Start and setting various options.
See 

Java Troubleshooting, Profiling, Monitoring and Management Tools

Tool NameBrief Description
jcmdJVM Diagnostic Commands tool – sends diagnostic command requests to a running Java Virtual Machine.
jconsoleA JMX-compliant graphical tool for monitoring a Java virtual machine. It can monitor both local and remote JVMs. It can also monitor and manage an application.
jmcThe Java Mission Control (JMC) client includes tools to monitor and manage your Java application without introducing the performance overhead normally associated with these types of tools.
jvisualvmA graphical tool that provides detailed information about the Java technology-based applications (Java applications) while they are running in a Java Virtual Machine. Java VisualVM provides memory and CPU profiling, heap dump analysis, memory leak detection, access to MBeans, and garbage collection.

Java Web Services Tools

Tool NameBrief Description
schemagenSchema generator for Java Architecture for XML Binding.
wsgenTool to generate JAX-WS portable artifacts.
wsimportTool to generate JAX-WS portable artifacts.
xjcBinding compiler for Java Architecture for XML Binding.

Monitoring Tools

You can use the following tools to monitor JVM performance statistics. The tools described in this section are unsupported and experimental, and should be used with that in mind. They may not be available in future JDK versions.

These tools are supported on all platforms except Windows 98 and Windows ME.

Tool NameBrief Description
jpsExperimental: JVM Process Status Tool – Lists instrumented HotSpot Java virtual machines on a target system.
jstatExperimental: JVM Statistics Monitoring Tool – Attaches to an instrumented HotSpot Java virtual machine and collects and logs performance statistics as specified by the command line options.
jstatdExperimental: JVM jstat Daemon – Launches an RMI server application that monitors for the creation and termination of instrumented HotSpot Java virtual machines and provides a interface to allow remote monitoring tools to attach to Java virtual machines running on the local system.

Troubleshooting Tools

The following tools can be used for specific troubleshooting tasks. The tools described in this section are unsupported and experimental in nature and should be used with that in mind. They may not be available in future JDK versions.

Some of these tools are not currently available on Windows platforms.

Tool NameBrief Description
jinfoExperimental – Configuration Info for Java – Prints configuration information for a given process or core file or a remote debug server.
jhatExperimental – Heap Dump Browser – Starts a web server on a heap dump file (for example, produced by jmap -dump), allowing the heap to be browsed.
jmapExperimental – Memory Map for Java – Prints shared object memory maps or heap memory details of a given process or core file or a remote debug server.
jsadebugdExperimental – Serviceability Agent Debug Daemon for Java – Attaches to a process or core file and acts as a debug server.
jstackExperimental – Stack Trace for Java – Prints a stack trace of threads for a given process or core file or remote debug server.

Scripting Tools

The following tool can be used to run scripts that interact with the Java platform. This tool is unsupported and experimental in nature and should be used with that in mind. It might not be available in future JDK versions.

Tool NameBrief Description
jrunscriptExperimental – Script shell for Java – Runs a scrip

Installing the JDK

When you run the JDK installer, you are offered a selection of three components: Development ToolsSource Code, and Public JRE. You may install one or all of them. In this case, just select the default.

Installing the “Development Tools” option gives you the JDK proper. Installing “Source Code” contains the sources for the public classes in the core Java API. Including this option allows you to reference the source code when building apps. The third option, “Public JRE,” drives home that the JDK and JRE are separate entities: the public JRE can be used by other programs to execute Java programs, and can be installed separately from the JDK.

Go ahead and install all three components and accept the defaults for each one. Doing this means your JDK and JRE will be installed in the default locations for your operating system. On Windows, that’s C:\Program Files\Java, as seen in Figure 3.

jw whatisjdk fig3
Figure 3. Java installed

What is the importance of Java Development Kit

?The Java Development Kit (JDK) is a software development environment that offers a collection of tools and libraries necessary for developing Java applications. You need the JDK to convert your source code into a format that the Java Runtime Environment (JRE) can execute.

Drop your comment

0Shares

Related Post

Leave a Reply

Your email address will not be published. Required fields are marked *