The Java Programming Language - PowerPoint PPT Presentation

1 / 8
About This Presentation
Title:

The Java Programming Language

Description:

Java Programs & Applets. Programs are compiled into classes ... According to Sun Microsystems, Java's future lies not only with the Internet but ... – PowerPoint PPT presentation

Number of Views:418
Avg rating:3.0/5.0
Slides: 9
Provided by: ronaldni
Category:

less

Transcript and Presenter's Notes

Title: The Java Programming Language


1
The Java Programming Language
  • Stand Alone Programs
  • Internet Applets
  • Structured with methods
  • Object Orientated Programming
  • Abstract Data Types
  • Use Beyond the PC

2
Java Programs Applets
  • Programs are compiled into classes
  • Programs are run by a Java Virtual Machine (JVM)
    (i.e. interpreter)
  • MS Visual J lets us compile into an .exe
  • Applets are compiled into classes
  • Applets are run by a JVM- usually a web browser
  • Applets are launched by an HTML web page.

3
Java Methods
  • Methods are like BASIC subroutines
  • Methods that return a value are similar to BASIC
    functions
  • When methods return a value they have a type
    (i.e. integer, string, double)
  • When methods do not return a value they are
    called void

4
Java Methods Public Private
  • Private methods are available only to the classes
    they are created in and the objects they are
    derived from.
  • Public methods can be executed from other classes
    and objects.

5
What is a Java class?
  • To the JVM, a class is compiled Java code
  • In respects to OOP, a class is a model from which
    objects can be created
  • To a programmer, a class in a tool for code reuse

6
Java Objects
  • Objects are created from classes
  • Multiple objects can be created from one class-
    this maximizes code reuse
  • Objects can be manipulated easily- similar to
    variables

7
Abstract Data Types
  • Classes and objects are considered abstract data
    types
  • Classes and objects are ways of better
    representing the world we live in.
  • An object can be thought of as the things around
    us.
  • A class can be thought of as a collection or
    category of objects

8
Why program in Java?
  • According to Sun Microsystems, Javas future lies
    not only with the Internet but with all household
    devices which will eventually become intelligent
    or computer automated.
  • Imagine the near future where all of our
    computerized possessions can recognize each other
    as Java objects.
Write a Comment
User Comments (0)
About PowerShow.com