SlideShare ist ein Scribd-Unternehmen logo
1 von 31
Introduction
to

Java
• Today Java , is one of the most popular programming
language which is used in critical applications like…

 web based applications
Embedded applications
 android mobile application.

Introduction
• Lets have a look in history of Java…
• Java was developed by James Gosling from Sun Microsystems in 1995.
• Introduced as an object-oriented language for general-purpose business
applications and for interactive, Web-based Internet applications.
• The goal was to provide platform-independent alternative to C++. In other
terms it is architecturally neutral, which means that you can use Java to
write a program that will run on any platform or device.
• Instead, Java runs on a Java Virtual Machine (JVM).

History & Evolution
• James Gosling ,Mike Sheridan and Patrick Naughton initiated the
green project in June 1991.
• Originally designed for small , embedded systems in electronic
appliances like set-top boxes.
• It was initially called as Oak and later on renamed as “Java” in 1995.
• Originally developed by James Gosling at Sun Microsystems in
1995.
• JDK 1.0 released in 1996.

History and Evolution
History of Java Releases
Java Version/Code Name

Release Date

Important Features/Code Name

JDK 1.0 (Oak)

23rd Jan 1996

Initial release

JDK 1.1

19th Feb 1997

Reflection , JDBC , Inner Classes
,RMI

J2SE 1.2 (Playground)

8th Dec 1998

Collection , JIT, String memory map

J2SE 1.3 (Kestrel)

8th May 2000

Java Sound , Java Indexing ,JNDI

J2SE 1.4 (Merlin)

6th Feb 2002

Assert , regex, exception chaining

J2SE 5.0 (Tiger)

30th Sept 2004

Generics ,autoboxing ,enums

Java SE 6.0 (Mustang)

11th Dec 2006

JDBC 4.0 , Java compiler API ,
Annotations

Java SE 7.0 (Dolphin)

28th July 2011

String in switch case ,exception
handling new way
Simple:
A Java programmer does not need to know the internal
functioning of Java, such as how memory is allocated to data.
Object-oriented:
Java supports the object-oriented approach to develop
programs.
Compiled and interpreted:
The Java programs are first compiled and then interpreted.
After the program is compiled, it is converted to a bytecode.
The Java Virtual Machine (JVM) then interprets this bytecode
into the computer code and runs it.
Portable:
Refers to the ability of a program to run on any platform without
changing the source code of a program.

Features of Java Environment
•

The following figure shows how the Java bytecode and the JVM together
make Java programs portable on different platforms.

Features of Java Environment
Distributed:
Java is designed for the distributed environment of the Internet
because it supports the various Internet protocols, such as
Transmission Control Protocols and Internet Protocol (TCP/IP).
Secure:
Java has built-in security features that verify that the programs
do not perform any destructive task, such as accessing the
files on a remote system.

Features of Java
Environment
• Java technology provides language part along with architecture for
running applications.
• Java Architecture provides
• Portable
• high-performance
• robust runtime environment.

• Various Components of Java Architecture are :
• Java Programming Language and class file
• JVM
• Java Application Programming Interface (API)

Java Architecture
• Java Runtime Environment contains JVM, class libraries and
other supporting components.
• Java source code is compiled into bytecode by Java compiler.
• This bytecode will be stored in class files.
• During runtime, this bytecode will be loaded, verified
and JVM interprets the bytecode into machine code which
will be executed in the machine in which the Java program
runs.

Java Runtime Environment (JRE)
• A Java Runtime Environment performs the following main
tasks respectively.
• Loads the class
• This is done by the class loader

• Verifies the bytecode
• This is done by bytecode verifier.

• Interprets the bytecode
• This is done by the JVM

Java Runtime Environment (JRE)
• Java programming language and class file:
• Java programs are saved with an extension, .java.
• A .java file is compiled to generate the .class file, which contains the
byte code.
• The JVM converts the byte code contained in the .class file to machine
object code.
• The JVM needs to be implemented for each platform running on a
different operating system.

Java Programming Lang. & Class file
• Its an abstract Machine forms the base of Java Platform.
• Specification that provides runtime environment in which java byte code
can be executed.
• Available for many hardware and software.

• JVM performs:
•
•
•
•

Loads code
Verifies code
Executes code
Provide Runtime Environment

Java Virtual Machine (JVM)
• Major Components of JVM
• Class Loader
• Byte code Verifier
• Just In Time (JIT) compiler

Java Virtual Machine
Interpreter
Byte
Code

Class
Loader

Byte code
Verifier

JIT Compiler

Java Runtime Environment

Java Virtual Machine

Running
Program
• Class Loader
• Class loader loads all the class files required to execute the
program.

• Byte code Verifier
•
•
•
•

Checks that code follows JVM specifications.
There is no unauthorized access to memory.
The code does not cause any stack overflows.
There are no illegal data conversions in the code such as float to
object references.

Components of JVM
• JIT Compiler
• Used to improve performance.
• It translates byte code only the first time.
• If repeated execution of code is required , it is automatically
mapped to the corresponding native machine code.
• JIT make use of the machine code which is cached and stored.

Components of JVM
Java Development Kit

• Package that provides the basic functionality of Java Language.
• Contains series of classes and methods

• Tools used to develop and execute java programs is known as JDK.
• It contains
•
•
•
•

Basic Tools( javac,java,javap,javadoc,appletviewer etc)
RMI tools (rmic,rmiregistry,rmid)
Security Tools (keytools,policytool etc.)
Java plug-in Tools
Basic Tools

Description

Javac

Compiler for java language

Java

Launcher of java application

Javadoc

API documentation generator

Appletviewer

Run and debug applets without a web
browser

Jar

Manage java archive files

Javap

Class file dissassembler

Java Development Kit
The Java API is a collection of software components that provide
capabilities, such as GUI.
The related classes and interfaces of the Java API are grouped
into packages.
The following figure shows how the Java API and the JVM forms
the platform for the Java programs on top of the hardware.

Java API
• Java can be used to develop more dynamic programs.
• Leading programming language for wireless technology and real time
embedded programming for cell phones.
• Major Categories of java programs :
• Applets
• Applications

Type of Java Programs
• Applets
• Small program embedded in a web page.
• Applets are downloaded over network and can make network
connections only to the host they are issued from.
• Graphical in nature and tends to contain controls like text field
, button label etc.

• Applications
•
•
•
•

Standalone programs written in java.
Invoked by using a JVM.
Can access the local file system.
Can execute on the server machine.

Types of Java Programs
• Temporary Path Setting
• Open command prompt
• Copy the path of bin folder
• Write in command prompt
• Set path=c:Program
FilesJavaJdk1.6.0_03bin;

• Permanent Path Setting
• Right click on My Computer
• Select Properties > Advanced tab >
Environment variables >new tab of
user variables > write path in
variable name > write path of bin
folder in variable value > ok

Setting Path for JDK in Windows
Java Program Life Cycle
• Create a source document using any editor such as Notepad and save file as
.java
• For example: HelloWorld.java

• Compile the java file using “javac” command. Byte Code will be
generated on disk.

Javac HelloWorld.java

After Compilation

HelloWorld.class

• This byte code can run on any platform or device having JVM using

“java”
Command.

StepS are….
class simple
{
public static void main(String args[])
{
System.out.println(“Hello Java”);
}
}

To Compile : javac simple.java
To Run
: java simple

Sample Java Program
• class : Used to declare class in java.
• public : Access modifier which represents the visibility.
• static : Keyword for creating static method , so that we can access it
without creating object.
• void : Return type of main method , its doesn’t return anything.
• main : Represent the startup of the program
• String args[] : Used to store command line arguments.

Understanding Sample
Program
Source Code
Program

Compiler

Byte code

Compilation Process

Compilation & Execution
R
U
N
T
I
M
E

P
R
O
C
E
S
S

Class file

Class Loader

Byte Code Verifier

Interpreter

Runtime

Compilation & Execution
Output Screen
• Built-in support for multi-threading, socket communication, and memory
management (automatic garbage collection).
• Object Oriented (OO).
• Better portability than other languages across operating systems.
• Supports Web based applications (Applet, Servlet, and JSP) .
• Supports distributed applications (sockets, RMI, EJB etc.) and network
protocols (HTTP, JRMP etc.) with the help of extensive standardized
APIs (Application Programming Interfaces).

Advantages of Java Programming
Language

Weitere ähnliche Inhalte

Was ist angesagt?

Introduction to java (revised)
Introduction to java (revised)Introduction to java (revised)
Introduction to java (revised)Sujit Majety
 
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...Edureka!
 
Core java complete ppt(note)
Core java  complete  ppt(note)Core java  complete  ppt(note)
Core java complete ppt(note)arvind pandey
 
Training on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan SanidhyaTraining on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan SanidhyaShravan Sanidhya
 
JRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAJRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAMehak Tawakley
 
Java Presentation For Syntax
Java Presentation For SyntaxJava Presentation For Syntax
Java Presentation For SyntaxPravinYalameli
 
Java Programming for Designers
Java Programming for DesignersJava Programming for Designers
Java Programming for DesignersR. Sosa
 
Java Presentation
Java PresentationJava Presentation
Java PresentationAmr Salah
 
Introduction to Java Programming Language
Introduction to Java Programming LanguageIntroduction to Java Programming Language
Introduction to Java Programming Languagejaimefrozr
 
Presentation on Core java
Presentation on Core javaPresentation on Core java
Presentation on Core javamahir jain
 
Core Java Tutorials by Mahika Tutorials
Core Java Tutorials by Mahika TutorialsCore Java Tutorials by Mahika Tutorials
Core Java Tutorials by Mahika TutorialsMahika Tutorials
 
Basics of JAVA programming
Basics of JAVA programmingBasics of JAVA programming
Basics of JAVA programmingElizabeth Thomas
 
Introduction to Java Programming
Introduction to Java ProgrammingIntroduction to Java Programming
Introduction to Java ProgrammingRavi Kant Sahu
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to javaSaba Ameer
 

Was ist angesagt? (20)

Introduction to java (revised)
Introduction to java (revised)Introduction to java (revised)
Introduction to java (revised)
 
Core java
Core javaCore java
Core java
 
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...
Java Tutorial For Beginners - Step By Step | Java Basics | Java Certification...
 
Core java complete ppt(note)
Core java  complete  ppt(note)Core java  complete  ppt(note)
Core java complete ppt(note)
 
Training on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan SanidhyaTraining on Core java | PPT Presentation | Shravan Sanidhya
Training on Core java | PPT Presentation | Shravan Sanidhya
 
JRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAJRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVA
 
Java Presentation For Syntax
Java Presentation For SyntaxJava Presentation For Syntax
Java Presentation For Syntax
 
Java Programming for Designers
Java Programming for DesignersJava Programming for Designers
Java Programming for Designers
 
Introduction to Java
Introduction to JavaIntroduction to Java
Introduction to Java
 
Java Presentation
Java PresentationJava Presentation
Java Presentation
 
Java
JavaJava
Java
 
Core java
Core javaCore java
Core java
 
Introduction to Java Programming Language
Introduction to Java Programming LanguageIntroduction to Java Programming Language
Introduction to Java Programming Language
 
Presentation on Core java
Presentation on Core javaPresentation on Core java
Presentation on Core java
 
Core Java Tutorials by Mahika Tutorials
Core Java Tutorials by Mahika TutorialsCore Java Tutorials by Mahika Tutorials
Core Java Tutorials by Mahika Tutorials
 
Arrays in Java
Arrays in Java Arrays in Java
Arrays in Java
 
Basics of JAVA programming
Basics of JAVA programmingBasics of JAVA programming
Basics of JAVA programming
 
Introduction to Java Programming
Introduction to Java ProgrammingIntroduction to Java Programming
Introduction to Java Programming
 
Core Java
Core JavaCore Java
Core Java
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to java
 

Andere mochten auch

Introduction to Java Programming
Introduction to Java Programming Introduction to Java Programming
Introduction to Java Programming Saravanakumar R
 
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Sakthi Durai
 
Tracking and positioning of mobile systems in telecommunication networks
Tracking and positioning of mobile systems in telecommunication networksTracking and positioning of mobile systems in telecommunication networks
Tracking and positioning of mobile systems in telecommunication networksgo2project
 
1 java programming- introduction
1  java programming- introduction1  java programming- introduction
1 java programming- introductionjyoti_lakhani
 
International Journal of Electrical Power System and Technology vol 2 issue 1
International Journal of Electrical Power System and Technology vol 2 issue 1International Journal of Electrical Power System and Technology vol 2 issue 1
International Journal of Electrical Power System and Technology vol 2 issue 1JournalsPub www.journalspub.com
 
Introduction to java 101
Introduction to java 101Introduction to java 101
Introduction to java 101kankemwa Ishaku
 
Core java concepts
Core java  conceptsCore java  concepts
Core java conceptsRam132
 
GSM Architecture
GSM ArchitectureGSM Architecture
GSM Architecturekoonlay
 
Telecommunication basics
Telecommunication basicsTelecommunication basics
Telecommunication basicsYoohyun Kim
 
telecommunication-ppt
telecommunication-ppttelecommunication-ppt
telecommunication-pptsecomps
 

Andere mochten auch (20)

Learn Java Part 2
Learn Java Part 2Learn Java Part 2
Learn Java Part 2
 
Introduction to Java Programming
Introduction to Java Programming Introduction to Java Programming
Introduction to Java Programming
 
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
 
Learn Java Part 1
Learn Java Part 1Learn Java Part 1
Learn Java Part 1
 
Tracking and positioning of mobile systems in telecommunication networks
Tracking and positioning of mobile systems in telecommunication networksTracking and positioning of mobile systems in telecommunication networks
Tracking and positioning of mobile systems in telecommunication networks
 
Introduction To Java.
Introduction To Java.Introduction To Java.
Introduction To Java.
 
Introduction to java technology
Introduction to java technologyIntroduction to java technology
Introduction to java technology
 
1 java programming- introduction
1  java programming- introduction1  java programming- introduction
1 java programming- introduction
 
International Journal of Electrical Power System and Technology vol 2 issue 1
International Journal of Electrical Power System and Technology vol 2 issue 1International Journal of Electrical Power System and Technology vol 2 issue 1
International Journal of Electrical Power System and Technology vol 2 issue 1
 
Introduction to java 101
Introduction to java 101Introduction to java 101
Introduction to java 101
 
Java Basics
Java BasicsJava Basics
Java Basics
 
02 basic java programming and operators
02 basic java programming and operators02 basic java programming and operators
02 basic java programming and operators
 
Core java concepts
Core java  conceptsCore java  concepts
Core java concepts
 
GSM Architecture
GSM ArchitectureGSM Architecture
GSM Architecture
 
Java basic
Java basicJava basic
Java basic
 
Telecommunication basics
Telecommunication basicsTelecommunication basics
Telecommunication basics
 
Core java slides
Core java slidesCore java slides
Core java slides
 
telecommunication-ppt
telecommunication-ppttelecommunication-ppt
telecommunication-ppt
 
Full gsm overview (modified)
Full gsm overview  (modified)Full gsm overview  (modified)
Full gsm overview (modified)
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to java
 

Ähnlich wie Introduction to java

JAVA_Day1_BasicIntroduction.pptx
JAVA_Day1_BasicIntroduction.pptxJAVA_Day1_BasicIntroduction.pptx
JAVA_Day1_BasicIntroduction.pptxMurugesh33
 
JAVAPart1_BasicIntroduction.pptx
JAVAPart1_BasicIntroduction.pptxJAVAPart1_BasicIntroduction.pptx
JAVAPart1_BasicIntroduction.pptxMurugesh33
 
PPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptPPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptRajeshSukte1
 
PPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptPPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptCDSukte
 
JavaClassPresentation
JavaClassPresentationJavaClassPresentation
JavaClassPresentationjuliasceasor
 
basic core java up to operator
basic core java up to operatorbasic core java up to operator
basic core java up to operatorkamal kotecha
 
Java fundamentals
Java fundamentalsJava fundamentals
Java fundamentalsOm Ganesh
 
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf10322210023
 
Java chapter 1 basic introduction Unit-1.pptx
Java chapter  1 basic introduction Unit-1.pptxJava chapter  1 basic introduction Unit-1.pptx
Java chapter 1 basic introduction Unit-1.pptxnoosdysharma
 
Lecture-01 _Java Introduction CS 441 Fast
Lecture-01 _Java Introduction CS 441 FastLecture-01 _Java Introduction CS 441 Fast
Lecture-01 _Java Introduction CS 441 FastUzairSaeed18
 
Java programming(unit 1)
Java programming(unit 1)Java programming(unit 1)
Java programming(unit 1)SURBHI SAROHA
 
1 Module 1 Introduction.pptx
1 Module 1 Introduction.pptx1 Module 1 Introduction.pptx
1 Module 1 Introduction.pptxBhargaviDalal3
 

Ähnlich wie Introduction to java (20)

JAVA PROGRAM CONSTRUCTS OR LANGUAGE BASICS.pptx
JAVA PROGRAM CONSTRUCTS OR LANGUAGE BASICS.pptxJAVA PROGRAM CONSTRUCTS OR LANGUAGE BASICS.pptx
JAVA PROGRAM CONSTRUCTS OR LANGUAGE BASICS.pptx
 
JAVA_Day1_BasicIntroduction.pptx
JAVA_Day1_BasicIntroduction.pptxJAVA_Day1_BasicIntroduction.pptx
JAVA_Day1_BasicIntroduction.pptx
 
JAVAPart1_BasicIntroduction.pptx
JAVAPart1_BasicIntroduction.pptxJAVAPart1_BasicIntroduction.pptx
JAVAPart1_BasicIntroduction.pptx
 
PPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptPPS Java Overview Unit I.ppt
PPS Java Overview Unit I.ppt
 
PPS Java Overview Unit I.ppt
PPS Java Overview Unit I.pptPPS Java Overview Unit I.ppt
PPS Java Overview Unit I.ppt
 
Java Introduction
Java IntroductionJava Introduction
Java Introduction
 
1.Intro--Why Java.pptx
1.Intro--Why Java.pptx1.Intro--Why Java.pptx
1.Intro--Why Java.pptx
 
JavaClassPresentation
JavaClassPresentationJavaClassPresentation
JavaClassPresentation
 
unit1.pptx
unit1.pptxunit1.pptx
unit1.pptx
 
java intro.pptx
java intro.pptxjava intro.pptx
java intro.pptx
 
basic core java up to operator
basic core java up to operatorbasic core java up to operator
basic core java up to operator
 
1 java introduction
1 java introduction1 java introduction
1 java introduction
 
1 java intro
1 java intro1 java intro
1 java intro
 
Java fundamentals
Java fundamentalsJava fundamentals
Java fundamentals
 
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf
1. JAVA_Module_1-edited - AJIN ABRAHAM.pptx.pdf
 
Java ppt1
Java ppt1Java ppt1
Java ppt1
 
Java chapter 1 basic introduction Unit-1.pptx
Java chapter  1 basic introduction Unit-1.pptxJava chapter  1 basic introduction Unit-1.pptx
Java chapter 1 basic introduction Unit-1.pptx
 
Lecture-01 _Java Introduction CS 441 Fast
Lecture-01 _Java Introduction CS 441 FastLecture-01 _Java Introduction CS 441 Fast
Lecture-01 _Java Introduction CS 441 Fast
 
Java programming(unit 1)
Java programming(unit 1)Java programming(unit 1)
Java programming(unit 1)
 
1 Module 1 Introduction.pptx
1 Module 1 Introduction.pptx1 Module 1 Introduction.pptx
1 Module 1 Introduction.pptx
 

Kürzlich hochgeladen

08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 

Kürzlich hochgeladen (20)

08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 

Introduction to java

  • 2. • Today Java , is one of the most popular programming language which is used in critical applications like…  web based applications Embedded applications  android mobile application. Introduction
  • 3. • Lets have a look in history of Java… • Java was developed by James Gosling from Sun Microsystems in 1995. • Introduced as an object-oriented language for general-purpose business applications and for interactive, Web-based Internet applications. • The goal was to provide platform-independent alternative to C++. In other terms it is architecturally neutral, which means that you can use Java to write a program that will run on any platform or device. • Instead, Java runs on a Java Virtual Machine (JVM). History & Evolution
  • 4. • James Gosling ,Mike Sheridan and Patrick Naughton initiated the green project in June 1991. • Originally designed for small , embedded systems in electronic appliances like set-top boxes. • It was initially called as Oak and later on renamed as “Java” in 1995. • Originally developed by James Gosling at Sun Microsystems in 1995. • JDK 1.0 released in 1996. History and Evolution
  • 5. History of Java Releases Java Version/Code Name Release Date Important Features/Code Name JDK 1.0 (Oak) 23rd Jan 1996 Initial release JDK 1.1 19th Feb 1997 Reflection , JDBC , Inner Classes ,RMI J2SE 1.2 (Playground) 8th Dec 1998 Collection , JIT, String memory map J2SE 1.3 (Kestrel) 8th May 2000 Java Sound , Java Indexing ,JNDI J2SE 1.4 (Merlin) 6th Feb 2002 Assert , regex, exception chaining J2SE 5.0 (Tiger) 30th Sept 2004 Generics ,autoboxing ,enums Java SE 6.0 (Mustang) 11th Dec 2006 JDBC 4.0 , Java compiler API , Annotations Java SE 7.0 (Dolphin) 28th July 2011 String in switch case ,exception handling new way
  • 6. Simple: A Java programmer does not need to know the internal functioning of Java, such as how memory is allocated to data. Object-oriented: Java supports the object-oriented approach to develop programs. Compiled and interpreted: The Java programs are first compiled and then interpreted. After the program is compiled, it is converted to a bytecode. The Java Virtual Machine (JVM) then interprets this bytecode into the computer code and runs it. Portable: Refers to the ability of a program to run on any platform without changing the source code of a program. Features of Java Environment
  • 7. • The following figure shows how the Java bytecode and the JVM together make Java programs portable on different platforms. Features of Java Environment
  • 8. Distributed: Java is designed for the distributed environment of the Internet because it supports the various Internet protocols, such as Transmission Control Protocols and Internet Protocol (TCP/IP). Secure: Java has built-in security features that verify that the programs do not perform any destructive task, such as accessing the files on a remote system. Features of Java Environment
  • 9. • Java technology provides language part along with architecture for running applications. • Java Architecture provides • Portable • high-performance • robust runtime environment. • Various Components of Java Architecture are : • Java Programming Language and class file • JVM • Java Application Programming Interface (API) Java Architecture
  • 10. • Java Runtime Environment contains JVM, class libraries and other supporting components. • Java source code is compiled into bytecode by Java compiler. • This bytecode will be stored in class files. • During runtime, this bytecode will be loaded, verified and JVM interprets the bytecode into machine code which will be executed in the machine in which the Java program runs. Java Runtime Environment (JRE)
  • 11. • A Java Runtime Environment performs the following main tasks respectively. • Loads the class • This is done by the class loader • Verifies the bytecode • This is done by bytecode verifier. • Interprets the bytecode • This is done by the JVM Java Runtime Environment (JRE)
  • 12. • Java programming language and class file: • Java programs are saved with an extension, .java. • A .java file is compiled to generate the .class file, which contains the byte code. • The JVM converts the byte code contained in the .class file to machine object code. • The JVM needs to be implemented for each platform running on a different operating system. Java Programming Lang. & Class file
  • 13. • Its an abstract Machine forms the base of Java Platform. • Specification that provides runtime environment in which java byte code can be executed. • Available for many hardware and software. • JVM performs: • • • • Loads code Verifies code Executes code Provide Runtime Environment Java Virtual Machine (JVM)
  • 14. • Major Components of JVM • Class Loader • Byte code Verifier • Just In Time (JIT) compiler Java Virtual Machine
  • 15. Interpreter Byte Code Class Loader Byte code Verifier JIT Compiler Java Runtime Environment Java Virtual Machine Running Program
  • 16. • Class Loader • Class loader loads all the class files required to execute the program. • Byte code Verifier • • • • Checks that code follows JVM specifications. There is no unauthorized access to memory. The code does not cause any stack overflows. There are no illegal data conversions in the code such as float to object references. Components of JVM
  • 17. • JIT Compiler • Used to improve performance. • It translates byte code only the first time. • If repeated execution of code is required , it is automatically mapped to the corresponding native machine code. • JIT make use of the machine code which is cached and stored. Components of JVM
  • 18. Java Development Kit • Package that provides the basic functionality of Java Language. • Contains series of classes and methods • Tools used to develop and execute java programs is known as JDK. • It contains • • • • Basic Tools( javac,java,javap,javadoc,appletviewer etc) RMI tools (rmic,rmiregistry,rmid) Security Tools (keytools,policytool etc.) Java plug-in Tools
  • 19. Basic Tools Description Javac Compiler for java language Java Launcher of java application Javadoc API documentation generator Appletviewer Run and debug applets without a web browser Jar Manage java archive files Javap Class file dissassembler Java Development Kit
  • 20. The Java API is a collection of software components that provide capabilities, such as GUI. The related classes and interfaces of the Java API are grouped into packages. The following figure shows how the Java API and the JVM forms the platform for the Java programs on top of the hardware. Java API
  • 21. • Java can be used to develop more dynamic programs. • Leading programming language for wireless technology and real time embedded programming for cell phones. • Major Categories of java programs : • Applets • Applications Type of Java Programs
  • 22. • Applets • Small program embedded in a web page. • Applets are downloaded over network and can make network connections only to the host they are issued from. • Graphical in nature and tends to contain controls like text field , button label etc. • Applications • • • • Standalone programs written in java. Invoked by using a JVM. Can access the local file system. Can execute on the server machine. Types of Java Programs
  • 23. • Temporary Path Setting • Open command prompt • Copy the path of bin folder • Write in command prompt • Set path=c:Program FilesJavaJdk1.6.0_03bin; • Permanent Path Setting • Right click on My Computer • Select Properties > Advanced tab > Environment variables >new tab of user variables > write path in variable name > write path of bin folder in variable value > ok Setting Path for JDK in Windows
  • 25. • Create a source document using any editor such as Notepad and save file as .java • For example: HelloWorld.java • Compile the java file using “javac” command. Byte Code will be generated on disk. Javac HelloWorld.java After Compilation HelloWorld.class • This byte code can run on any platform or device having JVM using “java” Command. StepS are….
  • 26. class simple { public static void main(String args[]) { System.out.println(“Hello Java”); } } To Compile : javac simple.java To Run : java simple Sample Java Program
  • 27. • class : Used to declare class in java. • public : Access modifier which represents the visibility. • static : Keyword for creating static method , so that we can access it without creating object. • void : Return type of main method , its doesn’t return anything. • main : Represent the startup of the program • String args[] : Used to store command line arguments. Understanding Sample Program
  • 28. Source Code Program Compiler Byte code Compilation Process Compilation & Execution
  • 29. R U N T I M E P R O C E S S Class file Class Loader Byte Code Verifier Interpreter Runtime Compilation & Execution
  • 31. • Built-in support for multi-threading, socket communication, and memory management (automatic garbage collection). • Object Oriented (OO). • Better portability than other languages across operating systems. • Supports Web based applications (Applet, Servlet, and JSP) . • Supports distributed applications (sockets, RMI, EJB etc.) and network protocols (HTTP, JRMP etc.) with the help of extensive standardized APIs (Application Programming Interfaces). Advantages of Java Programming Language