5. “Java: A simple , object –oriented , network- savvy,interpreted,robust,secure,artitecture-
neutral,portable,high performance, multithreaded dynamic language”.
◦ Simple :- Java is easy to learn and its syntax is quite simple, clean and easy to understand
◦ Object-Oriented :- In java everything is Object which has some data and behaviour. Java can be
easily extended as it is based on Object Model.
◦ Portable :- Java Byte code can be carried to any platform. No implementation dependent
features. Everything related to storage is predefined, example: size of primitive data types
◦ Platform independent :- Java is guaranteed to be write-once, run-anywhere language. On
compilation Java program is compiled into bytecode. This bytecode is platform independent
and can be run on any machine, plus this bytecode format also provide security
◦ Secured :- With java secure features it enable us to develop virus free, temper free system.
6. Cont…
◦ Robust :- Java makes an effort to eliminate error prone codes by emphasizing mainly on
compile time error checking and runtime checking.
◦ Architecture neutral :- it can be run on any architecture
◦ Dynamic and Interpreted
◦ High Performance :- provides high performance
◦ Multithreaded:- many work can be done at a time
◦ Distributed :it is distributed network
7. Plug-ins
◦ Java Plug-in technology is part of the current version of the Java Runtime Environment,
Standard Edition (Java SE).
◦ Java Plug-in technology, included as part of the Java Runtime Environment, Standard Edition
(Java SE), establishes a connection between popular browsers and the Java platform.
◦ This connection enables applets on Web sites to be run within a browser on the desktop.
◦ Java Plug-in is a software product that serves as a bridge between a browser and an external
JRE.
◦ A developer "tells" the browser to use this external JRE(Java Runtime Environment) by placing
special HTML tags on a Web page. Once this is done, a browser can run Java applets or
JavaBeans components that have access to all the features (within the limits of Java's security
model) of this external JRE.
8. Java API’s
◦ There are two types of Java programming language application programming interfaces (APIs):
◦ The official core Java API, contained in the Android (Google), SE (OpenJDK and Oracle), MicroEJ.
◦ These packages (java.* packages) are the core Java language packages, meaning that
programmers using the Java language had to use them in order to make any worthwhile use of
the Java language.
◦ Optional APIs that can be downloaded separately.
◦ The specification of these APIs are defined according to many different organizations in the
world (Alljoyn, OSGi, Eclipse, JCP, E-S-R, etc.).
9. JDK
◦ JDK is an acronym for Java Development Kit.
◦ The Java Development Kit (JDK) is a software development environment which is used to
develop Java applications and applets.
◦ It physically exists. It contains JRE + development tools.
◦ JDK is an implementation of any one of the below given Java Platforms released by Oracle
Corporation:
◦ Standard Edition Java Platform
◦ Enterprise Edition Java Platform
◦ Micro Edition Java Platform
◦ The JDK contains a private Java Virtual Machine (JVM) and a few other resources such as an
interpreter/loader (java), a compiler (javac), an archiver (jar), a documentation generator
(Javadoc), etc. to complete the development of a Java Application.
11. J2SE
◦ Java Platform, Standard Edition.
◦ Also known as Core Java, this is the most basic and standard version of Java.It’s the purest form
of Java, a basic foundation for all other editions.
◦ It consists of a wide variety of general purpose API’s (like java.lang, java.util) as well as many
special purpose APIs
◦ J2SE is mainly used to create applications for Desktop environment.
◦ It consist all the basics of Java the language, variables, primitive data types, Arrays, Streams,
Strings Java Database Connectivity(JDBC) and much more. This is the standard, from which all
other editions came out, according to the needs of the time.
◦ The famous JVM of Java, the heart of Java development, was also given by this edition only.It’s
because of this feature, that Java has such a wide usage.
12. J2E
◦ This was originally known as Java 2 Platform, Enterprise Edition, which was later changed to Java
Platform, Enterprise Edition (Java EE).
◦ This is one of the three computing platforms released by Sun Microsystems which was later
acquired by Oracle Corporation.
◦ The other two platforms are Java Standard Edition (Java SE) and Java Micro Edition (Java ME).
◦ J2EE is nothing but an extension of the Java SE based on the Java programming language used
for developing and deploying web-based enterprise applications.
◦ It consists of a set of APIs, services, and protocols that provide the functionality to develop
multi-tiered web-based applications.
◦ It includes several technologies that extend the functionality of the Java SE APIs, such as
Servlets, Connectors, Enterprise JavaBeans, etc.
13. Cont…
◦ It’s mainly used for applications which run on servers and accessible through browsers like
Chrome, Firefox, etc.
◦ It’s also used for developing web applications over World Wide Web by creating standardized
modular components to handle many aspects of programming.
◦ The J2EE architecture provides services to simplify the common challenges faced by developers
while developing modern applications, thereby making it easier to implement industry-standard
design patterns for greater efficiency and reliability.
◦ It is comprised of a significant set of APIs along with Java EE core technologies that help make
the most of enterprise development. Simply speaking, J2EE is just a part of Java with a powerful
set of libraries.
14. J2ME
◦ Java Platform, Micro Edition or Java ME is a computing platform for development and
deployment of portable code for embedded and mobile devices (micro-controllers, sensors,
gateways, mobile phones, personal digital assistants, TV set-top boxes, printers).
◦ Java ME was formerly known as Java 2 Platform, Micro Edition or J2ME.
◦ The platform uses the object-oriented Java programming language.
◦ It is part of the Java software-platform family. Java ME was designed by Sun Microsystems,
acquired by Oracle Corporation in 2010.
◦ J2ME (Java 2 Platform, Micro Edition) is a technology that allows programmers to use
the Java programming language and related tools to develop programs for
mobile wireless information devices such as cellular phones and personal digital assistants
(PDAs).
◦ J2ME consists of programming specifications and a special virtual machine, the K Virtual
Machine, that allows a J2ME-encoded program to run in the mobile device.
15. JVM
◦ JVM (Java Virtual Machine) is an abstract machine.
◦ It is a specification that provides runtime environment in which java bytecode can be executed.
◦ JVMs are available for many hardware and software platforms (i.e. JVM is platform dependent).
◦ It is:
◦ A specification where working of Java Virtual Machine is specified. But implementation
provider is independent to choose the algorithm. Its implementation has been provided by
Oracle and other companies.
◦ An implementation Its implementation is known as JRE (Java Runtime Environment).
◦ Runtime Instance Whenever you write java command on the command prompt to run the java
class, an instance of JVM is created.
17. Java Hotspot
◦ The Java HotSpot Virtual Machine is a core component of the Java SE platform distributed by
Oracle.
◦ It implements the Java Virtual Machine Specification, and is delivered as a shared library in the
Java Runtime Environment.
◦ As the Java bytecode execution engine, it provides Java runtime facilities, such as thread and
object synchronization, on a variety of operating systems and architectures.
◦ It features improved performance via methods such as just-in-time compilation and adaptive
optimization.
◦ With the Sun acquisition, Oracle has two major Java Virtual Machine (JVM) implementations, the
Java HotSpot VM and the Oracle JRockit JVM.
◦ In the short-to-medium term, both will continue as strategic JVMs with active investment.
18. JRE
◦ The Java Runtime Environment, or JRE, is a software layer that runs on top of a computer’s
operating system software and provides the class libraries and other resources that a
specific Java program needs to run.
◦ The JRE is one of three interrelated components for developing and running Java programs. The
other two components are as follows:
◦ The Java Development Kit, or JDK, is a set of tools for developing Java applications. Developers
choose JDKs by Java version and by package or edition—Java Enterprise Edition (Java EE), Java
Special Edition (Java SE), or Java Mobile Edition (Java ME). Every JDK always includes a
compatible JRE, because running a Java program is part of the process of developing a Java
program.
◦ The Java Virtual Machine, or JVM, executes live Java applications. Every JRE includes a default
JRE, but developers are free to choose another that meets the specific resource needs of their
applications.
19. Cont….
◦ The JRE combines Java code created using the JDK with the necessary libraries required to run it
on a JVM and then creates an instance of the JVM that executes the resulting program.
◦ JVMs are available for multiple operating systems, and programs created with the JRE will run
on all of them.
◦ In this way, the Java Runtime Environment is what enables a Java program to run in any
operating system without modification.
20. HotJava
◦ HotJava (later called HotJava Browser to distinguish it from HotJava Views) was a modular,
extensible web browser from Sun Microsystems implemented in Java.
◦ It was the first browser to support Java applets, and was Sun's demonstration platform for the then-
new technology.
◦ It has since been discontinued and is no longer supported.
◦ Furthermore, the Sun Download Center was taken down on July 31, 2011, and the download link on
the official site points to a placeholder page saying so.
◦ Hotjava is a web browser from Sun Microsystems that was written in Java.
◦ At the time (1996), it was the first web browser that was capable of supporting Java applets.
◦ Development of the browser originally began in 1994 under the name "WebRunner".
◦ It was criticized for slowness, which was due to the limitations of the Java Virtual Machine during that
time.
◦ Currently, Hotjava is no longer being produced and is no longer supported.
21. JAR
◦ JAR files are packaged with the ZIP file format, so you can use them for tasks such as lossless data
compression, archiving, decompression, and archive unpacking. These tasks are among the most
common uses of JAR files, and you can realize many JAR file benefits using only these basic features.
◦ Even if you want to take advantage of advanced functionality provided by the JAR file format such as
electronic signing, you'll first need to become familiar with the fundamental operations.
◦ To perform basic tasks with JAR files, you use the Java Archive Tool provided as part of the Java
Development Kit (JDK). Because the Java Archive tool is invoked by using the jar command.
◦ As a synopsis and preview of some of the topics to be covered in this section, the following table
summarizes common JAR file operations:
22. Common JAR file operations
Common JAR file operations
Operation Command
To create a JAR file jar cf jar-file input-file(s)
To view the contents of a JAR file jar tf jar-file
To extract the contents of a JAR file jar xf jar-file
To extract specific files from a JAR file jar xf jar-file archived-file(s)
To run an application packaged as a JAR file
(requires the Main-class manifest header)
java -jar app.jar
To invoke an applet packaged as a JAR file
<applet code=AppletClassName.class
archive="JarFileName.jar" width=width
height=height> </applet>
23. AWT
◦ The Abstract Window Toolkit (AWT) is Java's original platform-
dependent windowing, graphics, and user-interface widget toolkit, preceding Swing.
◦ The AWT is part of the Java Foundation Classes (JFC) — the standard API for providing
a graphical user interface (GUI) for a Java program.
◦ AWT is also the GUI toolkit for a number of Java ME profiles.
◦ For example, Connected Device Configuration profiles require Java runtimes on mobile
telephones to support the Abstract Window Toolkit.
◦ AWT stands for Abstract Window Toolkit. It is a platform dependent API for creating
Graphical User Interface (GUI) for java programs.
◦ Why AWT is platform dependent? Java AWT calls native platform (Operating systems)
subroutine for creating components such as textbox, checkbox, button etc.
24. Swing
◦ Java Swing is a part of Java Foundation Classes (JFC) that is used to create window-based
applications.
◦ It is built on the top of AWT (Abstract Windowing Toolkit) API and entirely written in java.
◦ Unlike AWT, Java Swing provides platform-independent and lightweight components.
◦ The javax.swing package provides classes for java swing API such as JButton, JTextField, JTextArea,
JRadioButton, JCheckbox, JMenu, JColorChooser etc.
◦ Java swing components are platform-independent.
◦ Swing components are lightweight.
◦ Swing supports pluggable look and feel.
◦ Swing provides more powerful components such as tables, lists, scrollpanes, colorchooser,
tabbedpane etc.
◦ Swing follows MVC(Model View Controller).
26. EXAMPLE
◦ import javax.swing.*;
◦ public class FirstSwingExample {
◦ public static void main(String[] args) {
◦ JFrame f=new JFrame();//creating instance of JFrame
◦ JButton b=new JButton("click");//creating instance of JButton
◦ b.setBounds(130,100,100, 40);//x axis, y axis, width, height
◦ f.add(b);//adding button in JFrame
◦ f.setSize(400,500);//400 width and 500 height
◦ f.setLayout(null);//using no layout managers
◦ f.setVisible(true);//making the frame visible
◦ }
◦ }
27. Applets
◦ An applet is a Java program that can be embedded into a web page.
◦ It runs inside the web browser and works at client side.
◦ An applet is embedded in an HTML page using the APPLET or OBJECT tag and hosted on a web
server.
◦ Applets are used to make the web site more dynamic and entertaining.
◦ Important points :
◦ All applets are sub-classes (either directly or indirectly) of java.applet.Applet class.
◦ Applets are not stand-alone programs. Instead, they run within either a web browser or an applet
viewer. JDK provides a standard applet viewer tool called applet viewer.
◦ In general, execution of an applet does not begin at main() method.
◦ Output of an applet window is not performed by System.out.println(). Rather it is handled with various
AWT methods, such as drawString().
29. Cont…
◦ It is important to understand the order in which the various methods shown in the above image
are called. When an applet begins, the following methods are called, in this sequence:
◦ init( )
◦ start( )
◦ paint( )
◦ When an applet is terminated, the following sequence of method calls takes place:
◦ stop( )
◦ destroy( )
30. Servlets
◦ Servlet technology is used to create a web application (resides at server side and generates a
dynamic web page).
◦ Servlet technology is robust and scalable because of java language. Before Servlet, CGI (Common
Gateway Interface) scripting language was common as a server-side programming language.
◦ There are many interfaces and classes in the Servlet API such as Servlet, GenericServlet, HttpServlet,
ServletRequest, ServletResponse, etc.
◦ Servlet can be described in many ways, depending on the context.
◦ Servlet is a technology which is used to create a web application.
◦ Servlet is an API that provides many interfaces and classes including documentation.
◦ Servlet is an interface that must be implemented for creating any Servlet.
◦ Servlet is a class that extends the capabilities of the servers and responds to the incoming requests. It
can respond to any requests.
◦ Servlet is a web component that is deployed on the server to create a dynamic web page.
32. JSP
◦ JSP technology is used to create web application just like Servlet technology.
◦ It can be thought of as an extension to Servlet because it provides more functionality than
servlet such as expression language, JSTL, etc.
◦ A JSP page consists of HTML tags and JSP tags.
◦ The JSP pages are easier to maintain than Servlet because we can separate designing and
development.
◦ It provides some additional features such as Expression Language, Custom Tags, etc.
33. The Lifecycle of a JSP Page
◦ The JSP pages follow these phases:
◦ Translation of JSP Page
◦ Compilation of JSP Page
◦ Classloading (the classloader loads class file)
◦ Instantiation (Object of the Generated Servlet is created).
◦ Initialization ( the container invokes jspInit() method).
◦ Request processing ( the container invokes _jspService() method).
◦ Destroy ( the container invokes jspDestroy() method).
35. Features of JSP
◦ Coding in JSP is easy :- As it is just adding JAVA code to HTML/XML.
◦ Reduction in the length of Code :- In JSP we use action tags, custom tags etc.
◦ Connection to Database is easier :-It is easier to connect website to database and allows to read
or write data easily to the database.
◦ Make Interactive websites :- In this we can create dynamic web pages which helps user to
interact in real time environment.
◦ Portable, Powerful, flexible and easy to maintain :- as these are browser and server independent.
◦ No Redeployment and No Re-Compilation :- It is dynamic, secure and platform independent so
no need to re-compilation.
◦ Extension to Servlet :- as it has all features of servlets, implicit objects and custom tags
36. Advantages of using JSP
◦ It does not require advanced knowledge of JAVA
◦ It is capable of handling exceptions
◦ Easy to use and learn
◦ It can tags which are easy to use and understand
◦ Implicit objects are there which reduces the length of code
◦ It is suitable for both JAVA and non JAVA programmer
◦ Disadvantages of using JSP
◦ Difficult to debug for errors.
◦ First time access leads to wastage of time
◦ It’s output is HTML which lacks features.
37. Java Bean
◦ A JavaBean is a Java class that should follow the following conventions:
o It should have a no-arg constructor.
o It should be Serializable.
o It should provide methods to set and get the values of the properties, known as getter and
setter methods.
◦ Why use JavaBean?
◦ According to Java white paper, it is a reusable software component. A bean encapsulates many
objects into one object so that we can access this object from multiple places. Moreover, it
provides easy maintenance.
38. JavaBean Properties
◦ A JavaBean property is a named feature that can be accessed by the user of the object. The
feature can be of any Java data type, containing the classes that you define.
◦ A JavaBean property may be read, write, read-only, or write-only. JavaBean features are
accessed through two methods in the JavaBean's implementation class:
◦ 1. getPropertyName ()
◦ For example, if the property name is firstName, the method name would be getFirstName() to
read that property. This method is called the accessor.
◦ 2. setPropertyName ()
◦ For example, if the property name is firstName, the method name would be setFirstName() to
write that property. This method is called the mutator.
39. Advantages of JavaBean
◦ The following are the advantages of JavaBean:/p>
◦ The JavaBean properties and methods can be exposed to another application.
◦ It provides an easiness to reuse the software components.
◦ Disadvantages of JavaBean
◦ The following are the disadvantages of JavaBean:
◦ JavaBeans are mutable. So, it can't take advantages of immutable objects.
◦ Creating the setter and getter method for each property separately may lead to the boilerplate
code.
40. Cont…
◦ JavaBeans are classes that encapsulate many objects into a single object (the bean). It is a java
class that should follow following conventions:
◦ Must implement Serializable.
◦ It should have a public no-arg constructor.
◦ All properties in java bean must be private with public getters and setter methods.
41. EXAMPLE
◦ / Java program to illustrate the
◦ // structure of JavaBean class
◦ public class TestBean {
◦ private String name;
◦ public void setName(String name)
◦ {
◦ this.name = name;
◦ }
◦ public String getName()
◦ { return name;
◦ }
◦ }
42. EJB
◦ EJB is an acronym for enterprise java bean.
◦ It is a specification provided by Sun Microsystems to develop secured, robust and scalable distributed
applications.
◦ There are 3 types of enterprise bean in java.
◦ Session Bean
◦ Session bean contains business logic that can be invoked by local, remote or webservice client.
◦ Message Driven Bean
◦ Like Session Bean, it contains the business logic but it is invoked by passing message.
◦ Entity Bean
◦ It encapsulates the state that can be persisted in the database. It is deprecated. Now, it is replaced
with JPA (Java Persistent API).
43. Disadvantages of EJB
◦ Requires application server
◦ Requires only java client. For other language client, you need to go for webservice.
◦ Complex to understand and develop ejb applications.
44. RMI
◦ The RMI (Remote Method Invocation) is an API that provides a mechanism to create distributed
application in java.
◦ The RMI allows an object to invoke methods on an object running in another JVM.
◦ The RMI provides remote communication between the applications using two
objects stub and skeleton.
◦ RMI uses stub and skeleton object for communication with the remote object.
◦ stub
◦ The stub is an object, acts as a gateway for the client side.
◦ All the outgoing requests are routed through it.
◦ It resides at the client side and represents the remote object.
◦ When the caller invokes method on the stub object, it does the following tasks:
45. Cont….
◦ It initiates a connection with remote Virtual Machine (JVM),
◦ It writes and transmits (marshals) the parameters to the remote Virtual Machine (JVM),
◦ It waits for the result.
◦ It reads (unmarshals) the return value or exception, and
◦ It finally, returns the value to the caller.
◦ skeleton
◦ The skeleton is an object, acts as a gateway for the server side object. All the incoming requests
are routed through it.
◦ When the skeleton receives the incoming request, it does the following tasks:
46. Cont…
◦ It reads the parameter for the remote method
◦ It invokes the method on the actual remote object, and
◦ It writes and transmits (marshals) the result to the caller.
47. JDBC
◦ JDBC stands for Java Database Connectivity.
◦ JDBC is a Java API to connect and execute the query with the database.
◦ It is a part of JavaSE (Java Standard Edition).
◦ JDBC API uses JDBC drivers to connect with the database.
◦ There are four types of JDBC drivers:
◦ JDBC-ODBC Bridge Driver,
◦ Native Driver,
◦ Network Protocol Driver, and
◦ Thin Driver
48. Cont…
◦ We can use JDBC API to access tabular data stored in any relational database.
◦ By the help of JDBC API, we can save, update, delete and fetch data from the database.
◦ It is like Open Database Connectivity (ODBC) provided by Microsoft.
49. Cont…
◦ We can use JDBC API to handle database using Java program and can perform the following
activities:
◦ Connect to the database
◦ Execute queries and update statements to the database
◦ Retrieve the result received from the database.
50. JMI
◦ The Object Management Group’s (OMG) Java Metadata Interface (JMI) specification defines a
platform-neutral infrastructure that enables the creation, storage, access, discovery, and exchange of
metadata.
◦ JMI is an API for accessing and manipulating metadata from Java.
◦ It can be viewed as an extensible metadata service for the Java platform that provides a common Java
programming model for accessing metadata.
◦ Any system that provides a JMI-compliant API to its public metadata is a JMI service.
◦ JMI provides the following to the J2EE environment:
◦ A metadata framework that provides a common Java programming model for accessing metadata.
◦ An framework for integration and interoperability for Java tools and applications.
◦ ·Integration with OMG modeling and metadata architecture.
51. Java 2D/Java 3D
◦ Multidimensional Arrays can be defined in simple words as array of arrays. Data in
multidimensional arrays are stored in tabular form (in row major order).
◦ Syntax:
◦ data_type[1st dimension][2nd dimension][]..[Nth dimension] array_name = new
data_type[size1][size2]….[sizeN];
◦ where:
◦ data_type: Type of data to be stored in the array. For example: int, char, etc.
◦ dimension: The dimension of the array created.
For example: 1D, 2D, 3D etc.
◦ array_name: Name of the array
◦ size1, size2, …, sizeN: Sizes of the dimensions respectively.
52. EXAMPLE
◦ Two dimensional array:
◦ int[][] twoD_arr = new int[10][20];
◦ Three dimensional array:
◦ int[][][] threeD_arr = new int[10][20][30];
55. DND
◦ Drag and drop (DnD) is a way to transfer data in an application.
◦ DnD allows us to transfer data by dragging a component and dropping it onto another component.
◦ The component dragged is called the drag source; it supplies the data to be transferred.
◦ The component dropped is called the drop target; it is the receiver of the data.
◦ The data transfer is accomplished using a Transferable object.
◦ Transferable is an interface in the java.awt.datatransfer package.
◦ The Transferable interface contains the following three methods:
◦ DataFlavor[] getTransferDataFlavors()
◦ boolean isDataFlavorSupported(DataFlavor flavor)
◦ Object getTransferData(DataFlavor flavor) throws UnsupportedFlavorException, IOException
◦ To enable the dragging on the component
◦ myComponent.setDragEnabled(true);
56. Java IDL
◦ Java IDL is a technology for distributed objects--that is, objects interacting on different platforms
across a network.
◦ Java IDL is similar to RMI (Remote Method Invocation), which supports distributed objects written
entirely in the Java programming language.
◦ However, Java IDL enables objects to interact regardless of whether they're written in the Java
programming language or another language such as C, C++, COBOL, or others.
◦ In software development, Java Interface Definition Language, or Java IDL, is an implementation of
the CORBA specification and enables interoperability and connectivity with heterogeneous objects.
◦ It is basically an Object Request Broker provided with JDK.
◦ The Java IDL enables distributed Web applications to transparently invoke operations on remote
network services using the industry standards interface description language (IDL) from Object
Management Group.
57. Java Collections
◦ Any group of individual objects which are represented as a single unit is known as the collection of the objects.
◦ In Java, a separate framework named the “Collection Framework” has been defined in JDK 1.2 which holds all the
collection classes and interface in it.
◦ The Collection interface (java.util.Collection) and Map interface (java.util.Map) are the two main “root” interfaces
of Java collection classes.
◦ Advantages of the Collection Framework: Since the lack of collection framework gave rise to the above set of
disadvantages, the following are the advantages of the collection framework.
◦ Consistent API: The API has a basic set of interfaces like Collection, Set, List, or Map, all the classes
(ArrayList, LinkedList, Vector, etc) that implement these interfaces have some common set of methods.
◦ Reduces programming effort: A programmer doesn’t have to worry about the design of the Collection but rather
he can focus on its best use in his program. Therefore, the basic concept of Object-oriented programming (i.e.)
abstraction has been successfully implemented.
58. Cont…
◦ Increases program speed and quality: Increases performance by providing high-performance
implementations of useful data structures and algorithms because in this case, the programmer
need not think of the best implementation of a specific data structure. He can simply use the
best implementation to drastically boost the performance of his algorithm/program.
◦ The Collection in Java is a framework that provides an architecture to store and manipulate the
group of objects.
◦ Java Collections can achieve all the operations that you perform on a data such as searching,
sorting, insertion, manipulation, and deletion.
◦ Java Collection means a single unit of objects.
◦ Java Collection framework provides many interfaces (Set, List, Queue, Deque) and classes
(ArrayList, Vector, LinkedList, PriorityQueue, HashSet, LinkedHashSet, TreeSet).
59. RSA Signature
◦ RSA algorithm is an asymmetric cryptography algorithm. Asymmetric actually means that it
works on two different keys i.e. Public Key and Private Key. As the name describes that the
Public Key is given to everyone and the Private key is kept private.
◦ An example of asymmetric cryptography :
◦ A client (for example browser) sends its public key to the server and requests for some data.
◦ The server encrypts the data using the client’s public key and sends the encrypted data.
◦ Client receives this data and decrypts it.
◦ Since this is asymmetric, nobody else except the browser can decrypt the data even if a third
party has the public key of browser.
60. X.509 Certificates
◦ An X.509 certificate is a digital certificate that uses the widely accepted international X.509 public key infrastructure
(PKI) standard to verify that a public key belongs to the user, computer or service identity contained within the
certificate.
◦ An X.509 certificate contains information about the identity to which a certificate is issued and the identity that
issued it. Standard information in an X.509 certificate includes:
◦ Version – which X.509 version applies to the certificate (which indicates what data the certificate must include)
◦ Serial number – the identity creating the certificate must assign it a serial number that distinguishes it from other
certificates
◦ Algorithm information – the algorithm used by the issuer to sign the certificate
◦ Issuer distinguished name – the name of the entity issuing the certificate (usually a certificate authority)
◦ Validity period of the certificate – start/end date and time
◦ Subject distinguished name – the name of the identity the certificate is issued to
◦ Subject public key information – the public key associated with the identity
◦ Extensions (optional)
61. JPDA
◦ The Java Platform Debugger Architecture (JPDA) is a collection of APIs to debug Java code.
◦ Java Debugger Interface (JDI) - defines a high-level Java language interface that developers can easily
use to write remote debugger application tools.
◦ Java Virtual Machine Tools Interface (JVMTI), a native interface that helps to inspect the state and to
control the execution of applications running in the Java Virtual Machine (JVM).
◦ Java Virtual Machine Debug Interface (JVMDI)- JVMDI was deprecated in J2SE 5.0 in favor of JVM TI,
and was removed in Java SE 6.
◦ Java Debug Wire Protocol (JDWP) - defines communication between debuggee (a Java application)
and debugger processes.
◦ JDI is the highest-layer of the Java Platform Debugger Architecture. It allows to access the JVM and
the internal variables of the debugged program. It also allows to set Breakpoints, stepping, and
handle threads