Top Banner
Apex T. G. India Pvt. Ltd Introduction To Java
27

Introduction to Java and its Platforms

Jan 23, 2015

Download

Technology

Apex Tgi

Java is a fast growing Programming Language. It is Platform independent works on the concept of write for one operating system run on another. Write once, run anywhere. In this PPT we are discussing about what is Java and its platforms
www.apextgi.in
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Introduction to Java and its Platforms

Apex T. G. India Pvt. Ltd

Introduction To Java

Page 2: Introduction to Java and its Platforms

Birth

• December, 1990• 13 people to find next wave of computing• Convergence of media next big wave• Oak: a video on demand receiver toolkit• *7: failed video on demand appliance• WebRunner: failed Oak Mosiac clone

– First browser to run Applets

Page 3: Introduction to Java and its Platforms

Early ChildhoodEarly Childhood

• April, 1995• Java: Front page news of San Jose Mercury• Netscape announces Java embedded browsers• Java released to the masses• 10,000 downloads in the first few months• 2,000 emails a day within weeks• Total bandwidth for Java site twice that of Sun’s

main site

Page 4: Introduction to Java and its Platforms

Teenage Years

• Java growth stabilizes• IBM gives keynote speech

– Introduces term “e-business”– Names Java as standard “e-business”

platform• 90% of online transaction happen with

the help of Java within a year.• Java growth explodes again• Java tried on embedded devices again

Page 5: Introduction to Java and its Platforms

Early Twenties

• 66 Java Technologies• 50 + Java Technologies in development• Open Architecture license

– Free usage– Intellectual property free

• Community Development process– No company control over Java

Page 6: Introduction to Java and its Platforms

Java vs. JavaScript

• Java is NOT JavaScript• Java is:

– Programming language– Server sided – client never sees it– Cannot change the state of an HTML

page• JavaScript is:

– Scripting language– Client sided – server never touches it– Can change the state of an HTML page

Page 7: Introduction to Java and its Platforms

What is Java?

• Programming Language• Platform independent

– Write for one operating system– Run on another

• Write once, run anywhere• Java Virtual Machine (JVM)

– Runs Java programs

Page 8: Introduction to Java and its Platforms

How do they do that?

• Two step compile• First Compile

– Done by the programmer– Platform neutral

• Second Compile– Done by the JVM (Java Virtual Machine)– Platform specific– User doesn’t do anything special– Doesn’t affect original file

Page 9: Introduction to Java and its Platforms

Java Advantages

• Cost• Architecture• Portability• Reusability

Page 10: Introduction to Java and its Platforms

Advantage: Cost

• Buying programming software is expensive

• Java is free– Regardless of total number of users

• Free tools– Editors– Enterprise Servers

• Free tools + free language = more free tools

Page 11: Introduction to Java and its Platforms

Advantage: Architecture

• Java distributed for free• Community board administered

– No company can “own” Java• Every day users can contribute:

– Idea– Code– Bug-fixes

• Your in control

Page 12: Introduction to Java and its Platforms

Advantage: Portability

• Java is platform independent– Compiled programs run on any system

• Compiled files can be compressed• Compressed files known as Jar files• Jar files executable

– Without uncompressing

Page 13: Introduction to Java and its Platforms

Advantage: Reusability

• Reusability is using past code in current problems– Not necessarily your code

• Some one has done your work• Use other’s work• Big time saver

Page 14: Introduction to Java and its Platforms

Enterprise (J2EE) Technologies

• JDBC• Java Servlet• Java Server Pages (JSPs)• Frameworks(Struts,Hibernate,Spri

ng)• Enterprise JavaBeans (EJBs)• Java Messaging Server (JMS)

Page 15: Introduction to Java and its Platforms

JDBC

• Data Access Interface• Access many data sources

– Database access– Spreadsheets– Flat Files

• Performs common task like– Connection pooling– Batch updates– Transaction management

Page 16: Introduction to Java and its Platforms

Java Servlet

• Server Side programming• Extends current web server functionality• Server and Platform independent• Similar to CGI scripting• Access to all Java Technologies• Focused on content generation

– Programmers don’t have to worry about design

Page 17: Introduction to Java and its Platforms

Java Server Pages (JSPs)

• Embedded in HTML pages• Creates dynamic content• Server Sided• Focused on content presentation

– Designers don’t worry about programming

• Looks like regular HTML of XML– Markup tag based

Page 18: Introduction to Java and its Platforms

Frameworks

• Java provide some framework technology that follow MVC-design pattern for programming.

• It provides Independency , Reusability, Security to web application.

• Struts , Hibernate, Spring are the frameworks technologies of java.

Page 19: Introduction to Java and its Platforms

Enterprise JavaBeans (EJBs)

• Focused on– Customizable– Reusable

• Interface with data sources– Databases– Existing Enterprise Information Systems

(Banner)• Write once, run anywhere

Page 20: Introduction to Java and its Platforms

Enterprise Java Beans (EJBs)

• Distributed Client/Server Model• Code executed on server

– Closer to the data– More powerful machine then client

• Code localized to server– Changing server code doesn’t cause

change in client code

Page 21: Introduction to Java and its Platforms

Java Messaging Service (JMS)

• Communication between components• Two styles of communication

– Point-to-point messaging• Like Email

– Publish/Subscribe• Like Email Lists

Page 22: Introduction to Java and its Platforms

Java Messaging Service (JMS)

• Synchronous– Sent once, not guaranteed to reach

server– Lost if not received

• Asynchronous– Sent until it is acknowledged– Queued until message is retrieved

Page 23: Introduction to Java and its Platforms

Example Enterprise Application

Insert DataSubmit Link

LinksDB

LinksServlet

Check data

Error PageErrorJSP

Formats Error

Insert

JDBCApp

Construct Insert

Error Message

Page 24: Introduction to Java and its Platforms

Example Enterprise Application

Get Classes ClassesServlet

ClassesEJB

Get ClassesEIS

(Banner)

Get Classes

Return ClassesReturn Classes

Format List

Class ListJSP

No NoticesClass List

LibraryJMS

Check Notices

Page 25: Introduction to Java and its Platforms

Who should use Java?

• People who:– Program Enterprise systems– Interact with environments out of their

control– Want maximum flexibility– Maintain large websites

Page 26: Introduction to Java and its Platforms

Who shouldn’t use Java?

• People who:– Maintain small website– Don’t interact external sites or systems– Looking for a quick and dirty solution