Object-Oriented Programming Using Java

Slides:



Advertisements
Similar presentations
What is a Computer Program? For a computer to be able to do anything (multiply, play a song, run a word processor), it must be given the instructions.
Advertisements

1 Copyright © 2005, Oracle. All rights reserved. Introducing the Java and Oracle Platforms.
1 G54PRG Programming Lecture 1 Amadeo Ascó Adam Moore G54PRG Programming Lecture 1 Amadeo Ascó 3 Java Programming Language.
In Review JAVA C++ GUIs - Windows Webopedia.com.
Java: History and Introduction (Lecture # 1). History… Java – Based on C and C++ – Developed in 1991 for intelligent consumer electronic devices – Green.
Lecture 2: Do you speak Java?. From Problem to Program Last Lecture we looked at modeling with objects! Steps to solving a business problem –Investigate.
1 Programming & Programming Languages Overview l Machine operations and machine language. l Example of machine language. l Different types of processor.
For more Lectures and Notes Visit
Lecture 2: Do you speak Java?. From Problem to Program Last Lecture we looked at modeling with objects! Steps to solving a business problem –Investigate.
Introduction to Programming with Java, for Beginners Machine vs. Programming Language Intro to Java Edit-Compile-Run Program Process.
Course: Introduction to Computers
L EC. 01: J AVA FUNDAMENTALS Fall Java Programming.
01 Introduction to Java Technology. 2 Contents History of Java What is Java? Java Platforms Java Virtual Machine (JVM) Java Development Kit (JDK) Benefits.
LESSON 1 INTRODUCTION Compiled By: Edwin O. Okech [Tutor, Amoud University] JAVA PROGRAMMING.
Advanced OOP MCS-3 OOP BSCS-3 Lecture # 1
Introduction to Java Tonga Institute of Higher Education.
Introduction to Java CSIS 3701: Advanced Object Oriented Programming.
Parts of a Computer Why Use Binary Numbers? Source Code - Assembly - Machine Code.
Fall AboutMichael Fung, CS&E, The Chinese University of HK1 CSC1030 Hands-on Introduction to JAVA Dept of Computer Science and Engineering The.
CSCI 224 Introduction to Java Programming. Course Objectives  Learn the Java programming language: Syntax, Idioms Patterns, Styles  Become comfortable.
High-level Languages.
CMSC 202 Computer Science II for Majors Object-Oriented Programming.
Liang, Introduction to Java Programming, Sixth Edition, (c) 2007 Pearson Education, Inc. All rights reserved Programming Languages Machine.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
Introduction to Java CSIS 3701: Advanced Object Oriented Programming.
CS1Q Computer Systems Lecture 14 Simon Gay. Lecture 14CS1Q Computer Systems - Simon Gay2 Where we are Global computing: the Internet Networks and distributed.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
Computer Programming A program is a set of instructions a computer follows in order to perform a task. solve a problem Collectively, these instructions.
Chapter 34 Java Technology for Active Web Documents methods used to provide continuous Web updates to browser – Server push – Active documents.
aMichael Fung, CS&E, The Chinese University of HK1 Hands-on Introduction to JAVA Introduction to Java.
INTRODUCTION TO JAVA AND ANDROID. Slide 2 Our Ecosystem Java Eclipse Android SDK.
© 2012 Pearson Education, Inc. All rights reserved. 1-1 Why Java? Needed program portability – Program written in a language that would run on various.
Chapter 1: Introduction to Programs, and Java 1. Objectives To review programs (§ ). To understand the relationship between Java and the World Wide.
National Taiwan University Department of Computer Science and Information Engineering National Taiwan University Department of Computer Science and Information.
Getting started with Programming using IDE. JAVA JAVA IS A PROGRAMMING LANGUAGE AND A PLATFORM. IT CAN BE USED TO DELIVER AND RUN HIGHLY INTERACTIVE DYNAMIC.
JAVA Programming “When you are willing to make sacrifices for a great cause, you will never be alone.” Instructor: รัฐภูมิ เถื่อนถนอม
A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well.
Application Architecture Using Java Hong Li. Introduction Developed by a team led by James Gosling at Sun Microsystem. Originally called Oak, designed.
© 2012 Pearson Education, Inc. All rights reserved types of Java programs Application – Stand-alone program (run without a web browser) – Relaxed.
CS 178: Programming with Multimedia Objects Aditya P. Mathur Professor of Computer Sciences Purdue University, West Lafayette August 27, 2004 Last update:
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
1 Introduction to Java. 2 * 10% Assignments/ class participation * 10% Pop Quizzes * 05% Attendance * 25% Mid Term * 50% Final Term.
1 Introduction Read D&D Sec 1.8; Sec 1.13 THE Java tutorial -
Mobile Programming Mobile Programming - Ordibehesht Ordibehesht 1390.
Computer Programming Week 1: The Basics of CP 1 st semester 2012 School of Information Technology Website:
Liang, Introduction to Java Programming, Sixth Edition, (c) 2007 Pearson Education, Inc. All rights reserved Chapter 1 Introduction to Computers,
Introduction to JAVA Programming
Java Programming, 3e Concepts and Techniques Chapter 1 Section 56 – An Introduction to Java.
Fundamental of Java Programming (630002) Unit – 1 Introduction to Java.
Introduction to Algorithm. What is Algorithm? an algorithm is any well-defined computational procedure that takes some value, or set of values, as input.
Applications Active Web Documents Active Web Documents.
Computer Systems Nat 5 Computing Science
Object Oriented Programming in
Hardware and Software Hardware refers to the physical devices of the computer system e.g. monitor, keyboard, printer, RAM etc. Software is a set of programs,
Object-Oriented Programming Using Java
Chapter 1 Introduction to Computers, Programs, and Java
Lecture 1: Introduction to JAVA
Computer Systems Nat 5 Computing Science
Java History Background information about Java and how the background affected it’s development 1.
Java programming lecture one
Introduction Enosis Learning.
Introduction CSE 1310 – Introduction to Computers and Programming
Introduction Enosis Learning.
Chapter 1 Introduction to Computers, Programs, and Java
Hands-on Introduction to JAVA
COMPUTER SOFT WARE Software is a set of electronic instructions that tells the computer how to do certain tasks. A set of instructions is often called.
Introduction CSC 111.
Java History, Editions, Version Features
Outcome of the Lecture Upon completion of this lecture you will be able to understand Fundamentals and Characteristics of Java Language Basic Terminology.
Presentation transcript:

Object-Oriented Programming Using Java Introduction to Java 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Michael Fung, CS&E, The Chinese University of HK Hard and Soft Physical devices comprising a computer system are referred to as hardware. Computer programs that run on a computer are referred to as software. 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Software: Program and Data A computer program is merely a collection of instructions to process data. This course is focused on how to design and produce quality software, i.e. writing complete and precise computer programs to control computers. 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

What is Data in Computer? ICQ/Email message, web page Movie, image, song Teaching time table, Grade Point Average ICQ/Phone/credit card number Joy-pad button status, weapon list in Diablo II Text document Program Basically anything in computer manageable form! 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Compiler / Interpreter Still remember the Pros & Cons of writing High-level & Low-level language? Translators do the translation task for us Program Written in High-level Language e.g. Pascal, C Compiler/Interpreter Executable Program in Low-level Language e.g. Intel x86 code 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Really Cross Platform?! SGI Octane Pentium 4 Translate Translate Basic Program [hello.bas] Translate Translate Translate Macintosh Sun UltraSparc … 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Michael Fung, CS&E, The Chinese University of HK Pitfalls Store and use different compiled versions Availability of compiler(s) is a must Compiler compatibility problem Re-compile all versions after an update How about a new machine/ computer architecture? 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Widely-used in corporations! Java? Widely-used in corporations! 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Michael Fung, CS&E, The Chinese University of HK Java? Web-based applications Enterprise usage Home usage Mobile usage Set-top box, e.g. cable TV ... 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Java Compilation Model Java Program [hello.java] Java Compiler Compile Java Byte Code [hello.class] We do this once 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Java Compilation Model Someone do this for us native code Pentium 4 Java Byte Code [hello.class] Translate SGI Octane Macintosh Java Virtual Machine (JVM) Sun UltraSparc 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Java Compilation Model Java Program [hello.java] The whole grand picture native code Java Compiler Compile Pentium 4 Java Byte Code [hello.class] Translate SGI Octane Macintosh Java Virtual Machine (JVM) Sun UltraSparc 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Michael Fung, CS&E, The Chinese University of HK Scenario Explained Now, each native speaker has an in-house translator who understands Java Byte Code and speaks the corresponding native language We, as a foreigner, only need to prepare our instruction in Java Byte Code However, Java Byte Code is still hard for human, so we learn the Java Language 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Portability: 海納百川、有容乃大 Java is an Object-Oriented Programming Language, supporting standalone text applications standalone graphical applications client-side web development (applet) server-side web development (servlet, JSP) mobile applications (J2ME, MIDP, games, etc.) embedded applications (Java card, set-top box) 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK

Michael Fung, CS&E, The Chinese University of HK Summary Java is compiled to byte code and can be run on any platform that supports a Java Virtual Machine. [portable] Java Platform is available in Standard Edition (SE), Enterprise Edition (EE), or Micro Edition (ME). NetBeans is a graphical IDE bundled with Java for developing projects in Java. 2008-2009 1a Michael Fung, CS&E, The Chinese University of HK