programming software applications week 1 dr xiaohong gao trent park b107 ext 2252 x gao@mdx ac uk n.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Programming Software Applications Week 1 Dr. Xiaohong Gao Trent Park – B107, ext. 2252 PowerPoint Presentation
Download Presentation
Programming Software Applications Week 1 Dr. Xiaohong Gao Trent Park – B107, ext. 2252

Loading in 2 Seconds...

play fullscreen
1 / 30

Programming Software Applications Week 1 Dr. Xiaohong Gao Trent Park – B107, ext. 2252 - PowerPoint PPT Presentation


  • 74 Views
  • Uploaded on

Programming Software Applications Week 1 Dr. Xiaohong Gao Trent Park – B107, ext. 2252 x.gao@mdx.ac.uk. Course Objectives (1/2). Upon completing the course, you will understand : Java applications Primitive data types Java control flow Methods Object-oriented programming Inheritance

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Programming Software Applications Week 1 Dr. Xiaohong Gao Trent Park – B107, ext. 2252' - infinity


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
programming software applications week 1 dr xiaohong gao trent park b107 ext 2252 x gao@mdx ac uk
Programming Software Applications

Week 1

Dr. Xiaohong Gao

Trent Park – B107, ext. 2252

x.gao@mdx.ac.uk

course objectives 1 2
Course Objectives (1/2)

Upon completing the course, you will understand :

  • Java applications
  • Primitive data types
  • Java control flow
  • Methods
  • Object-oriented programming
  • Inheritance
  • Polymorphism
  • Core Java classes (Swing)
  • Graphics
course objectives 2 2
Course Objectives (2/2)

You will be able to :

  • Write applications
  • Develop a simple GUI interface
  • Write interesting projects
  • Establish a firm foundation on Java concepts
learning patterns
Learning Patterns
  • Lecturer(1.5 hours): theory with sample programs
  • Labs (1.5 hours) : Practice theory using Java programs
  • Workshops/seminars: discussion/reflection
assessment pattern
Assessment Pattern
  • Exam (3 hours) ---- 70

Course work ---- 30%

2 Mini-tasks

10%

Project

20%

Note: You have to pass both coursework and exam in order to pass the module.

contact information
Contact Information
  • Duty tutor time
          • Friday, 12:30-13:30, Bevan Building
  • Email

x.gao@mdx.ac.uk

  • Learning Materials

http://www.cs.mdx.ac.uk/staffpages/xiaohong/cmt4001

introduction to java
Introduction to Java

Objectives

What Is Java?

  • Getting Started With Java Programming
  • Compiling and Running a Java Application
  • Compiling and Running a Java Applet
slide9

2. File  New

3. File  Save As  Hello1.java

what is java
What Is Java?
  • History
  • Characteristics of Java
history
History
  • James Gosling
      • Oak
  • Java, May 20, 1995, Sun World
  • HotJava
    • The first Java-enabled Web browser
characteristics of java
Characteristics of Java
  • Java is simple
  • Java is object-oriented
  • Java is distributed
  • Java is interpreted
  • Java is robust
  • Java is secure
characteristics of java1
Characteristics of Java
  • Java is architectural-neutral
  • Java is portable
  • Java’s performance
  • Java is multithreaded
  • Java is dynamic
jdk versions
JDK Versions
  • JDK 1.02 (1995)
  • JDK 1.1 (1996)
  • Java 2 SDK v 1.2 (a.k.a JDK 1.2, 1998)
  • Java 2 SDK v 1.3 (a.k.a JDK 1.2, 2000)
  • Java 2 SDK v 1.4
java ide tools
Java IDE Tools
  • Inprise JBuilder (RAD) (www.inprise.com)
  • Microsoft Visual J++ (www.microsoft.com)
  • Visual Café by WebGain (www.webgain.com)
  • JFactory by Rouge Wave (www.rougewave.com)
  • Forte by Sun (www.javasoft.com)
  • IBM Visual Age for Java (RAD) (www.ibm.com)
getting started with java programming
Getting Started with Java Programming
  • A Simple Java Application

Compiling Programs

Executing Applications

  • A Simple Java Applet

Viewing Java Applets

  • Applications vs. Applets
a simple application
A Simple Application

Example:

//This application program prints Welcome

//to Java!

public class Welcome

{

public static void main(String[] args)

{

System.out.println("Welcome to Java!");

}

}

compiling programs
Compiling Programs
  • On command line
    • javac file.java
executing applications
Executing Applications
  • On command line
    • java classname
example
Example

javac Welcome.java

java Welcome

output:...

a simple applet optional
A Simple Applet (Optional)

Example

/* This is an example of Java applets */

import java.awt.Graphics;

public class WelcomeApplet

extends java.applet.Applet

{

public void paint (Graphics g)

{

g.drawString("Welcome to Java!",10,10);

}

}

creating an html file
Creating an HTML File

<html>

<body>

<applet code="WelcomeApplet.class"

width = 100 height = 40>

</applet>

</body>

</html>

applet viewer utility
Applet Viewer Utility

appletviewer htmlfile.html

Example:

appletviewer WelcomeApplet.html

applications vs applets
Applications vs. Applets
  • Similarities
  • Differences
security restrictions on applets
Security Restrictions on Applets
  • Applets are not allowed to read from, or write to, the file system of the computer viewing the applets.
  • Applets are not allowed to run any programs on the browser’s computer.
  • Applets are not allowed to establish connections between the user’s computer and another computer except with the server wherethe applets are stored.
java books
Java books
  • Dietel & Dietel
  • “Advanced Java 2 Platform -How to program”
  • Prentice Hall,last edition
  • Judith Bishop
  • “Java Gently,Third edition,Addison-Wesley”
summary
Summary
  • Introduction to the module
  • Java characteristics