COP%203330 - PowerPoint PPT Presentation

About This Presentation
Title:

COP%203330

Description:

Java Virtual Machine. Java is compiled to Java bytecode, ... to machine code except that it is meant for the Java Virtual Machine (JVM) ... Java Virtual Machine ... – PowerPoint PPT presentation

Number of Views:23
Avg rating:3.0/5.0
Slides: 25
Provided by: benjamin117
Learn more at: http://www.cs.ucf.edu
Category:

less

Transcript and Presenter's Notes

Title: COP%203330


1
COP 3330
  • Notes 1/12

2
Today's topics
  • Downloading Java and Eclipse
  • Hello World
  • Basic control structures
  • Basic I/O
  • Strings

3
Downloading Java
4
Downloading Java
5
Downloading Java
6
Downloading Eclipse
7
Downloading Eclipse
8
Creating a Java Program With Eclipse
9
Creating a Java Program With Eclipse
10
Creating a Java Program With Eclipse
11
Creating a Java Program With Eclipse
12
Creating a Java Program With Eclipse
13
Running a Java Program With Eclipse
14
Running a Java Program With Eclipse
  • Double-click Java Application

15
Running a Java Program With Eclipse
16
Running a Java Program Using Command Line
17
Running a Java Program Using Command Line
18
Running a Java Program Using Command Line
19
Running a Java Program Using Command Line
  • Add the path of the bin directory of your JDK
    install to your path environment variable
  • In my case
  • C\Program Files\Java\jdk1.5.0_04\bin

20
Running a Java Program Using Command Line
21
Running a Java Program Using Command Line
22
Running a Java Program Using Command Line
  • If you get the error
  • Exception in thread "main" java.lang.NoClassDefFou
    ndError HelloWorldApp
  • Make sure youre in the same directory as your
    .java file and that you typed everything
    correctly
  • If you still get the error, type at the command
    line set CLASSPATH

23
Java Virtual Machine
  • Java is compiled to Java bytecode, not machine
    language
  • Java bytecode is similar to machine code except
    that it is meant for the Java Virtual Machine
    (JVM)
  • The JVM is an interpreter of Java bytecode (i.e.
    it runs Java programs)

24
Java Virtual Machine
  • Machine language must be specific to a processor,
    so programs written in most languages must be
    recompiled to run on different processors
  • The same compiled Java program can run on any
    computer that can run the correct version of the
    JVM
Write a Comment
User Comments (0)
About PowerShow.com