Advanced Object-Oriented Programming Introduction to OOP and Java

Similar documents
CS260 Intro to Java & Android 02.Java Technology

Outline. Introduction to Java. What Is Java? History. Java 2 Platform. Java 2 Platform Standard Edition. Introduction Java 2 Platform

1. Introduction. Java. Fall 2009 Instructor: Dr. Masoud Yaghini

Introduction to Java. Lecture 1 COP 3252 Summer May 16, 2017

History Introduction to Java Characteristics of Java Data types

Introduction to Visual Basic and Visual C++ Introduction to Java. JDK Editions. Overview. Lesson 13. Overview

Lecture 1: Overview of Java

II. Compiling and launching from Command-Line, IDE A simple JAVA program

Notes of the course - Advanced Programming. Barbara Russo

Seminar report Java Submitted in partial fulfillment of the requirement for the award of degree Of CSE

Learning objectives. The Java Environment. Java timeline (cont d) Java timeline. Understand the basic features of Java

Introduction to Java Programming

Introduction to Java

[Course Overview] After completing this module you are ready to: Develop Desktop applications, Networking & Multi-threaded programs in java.

CT 229. CT229 Lecture Notes. Labs. Tutorials. Lecture Notes. Programming II CT229. Objectives for CT229. IT Department NUI Galway

Chapter 1 Introduction to Computers, Programs, and Java. What is a Computer? A Bit of History

Object Oriented Concepts and Programming (CSC244) By Dr. Tabbasum Naz

MODULE 1 JAVA PLATFORMS. Identifying Java Technology Product Groups

CSE 421 Course Overview and Introduction to Java

Programming Languages FILS Andrei Vasilateanu

Assoc. Prof. Dr. Marenglen Biba. (C) 2010 Pearson Education, Inc. All rights reserved.

Introduction to Java Programming CPIT 202. WEWwwbvxnvbxmnhsgfkdjfcn

Chapter 1 GETTING STARTED. SYS-ED/ Computer Education Techniques, Inc.

Certified Core Java Developer VS-1036

Index. Course Outline. Grading Policy. Lab Time Distribution. Important Instructions

CS5015 Object-oriented Software Development. Lecture: Overview of Java Platform. A. O Riordan, 2010 Most recent revision, 2014 updated for Java 8

CHAPTER 1. Introduction to JAVA Programming

Lecture 1: Introduction to Java

Java Programming Language Mr.Rungrote Phonkam

Chapter 1 Introduction to Java

Introduction to Java. Nihar Ranjan Roy.

Atelier Java - J1. Marwan Burelle. EPITA Première Année Cycle Ingénieur.

Introduction to Java

WA1278 Introduction to Java Using Eclipse

From High Level to Machine Code. Compilation Overview. Computer Programs

Introduction to JAVA Programming Language

Chapter 1: Introduction to Computers and Java

OBJECT ORIENTED PROGRAMMING

High-Level Language VMs

8/23/2014. Chapter Topics. Introduction. Java History. Why Program? Java Applications and Applets. Chapter 1: Introduction to Computers and Java

Chapter 1 INTRODUCTION SYS-ED/ COMPUTER EDUCATION TECHNIQUES, INC.

02/03/15. Compile, execute, debugging THE ECLIPSE PLATFORM. Blanks'distribu.on' Ques+ons'with'no'answer' 10" 9" 8" No."of"students"vs."no.

Answer1. Features of Java

Chapter 1 Introduction to Computers, Programs, and Java

Introduction. Introduction to OOP with Java. Lecture 01: Introduction to OOP with Java - AKF Sep AbuKhleiF -

Introduction to. Android Saturday. Yanqiao ZHU Google Camp School of Software Engineering, Tongji University. In courtesy of The Java Tutorials

CHAPTER 1 Introduction to Computers and Java

DOWNLOAD OR READ : JAVA THREADS PDF EBOOK EPUB MOBI

Distributed Multitiered Application

AN ISO 9001:2008 CERTIFIED COMPANY ADVANCED. Java TRAINING.

Introduction to OOP with Java. Instructor: AbuKhleif, Mohammad Noor Sep 2017

Chapter 1 Introduction to Computers, Programs, and Java

JAVA+ANDROID CURRICULUM 6 WEEKS. INTRODUCTION TO JAVA Understanding Requirement: Why Java Why Java is important to the Internet JAVA on LINUX Platform

Appendix A - Glossary(of OO software term s)

Programming. Syntax and Semantics

C++ Spring Break Packet 11 The Java Programming Language

Chapter 4: Threads. Overview Multithreading Models Thread Libraries Threading Issues Operating System Examples Windows XP Threads Linux Threads

Course Description. Learn To: : Intro to JAVA SE7 and Programming using JAVA SE7. Course Outline ::

2 rd class Department of Programming. OOP with Java Programming

Java language. Part 1. Java fundamentals. Yevhen Berkunskyi, NUoS

Runtime Application Self-Protection (RASP) Performance Metrics

MARS AREA SCHOOL DISTRICT Curriculum TECHNOLOGY EDUCATION

Computational Applications in Nuclear Astrophysics using Java Java course Lecture 1

JAVA An overview for C++ programmers

SELF-STUDY. Glossary

What we need. Agenda. What s J2EE. Challenges of Enterprise Application Development

Introduction to Java

Another difference is that the kernel includes only the suspend to memory mechanism, and not the suspend to hard disk, which is used on PCs.

What Is NetBeans? Free and open-source based > Open source since June, 2000 > Large community of users and developers

Getting Started with Java. Atul Prakash

Module 1: Introduction to Computers, Programs, and Java

From C++ to Java. Duke CPS

Special Topics: Programming Languages

IQTIDAR ALI Lecturer IBMS Agriculture University Peshawar

StackVsHeap SPL/2010 SPL/20

23/02/15. Compile, execute, debug. Advanced Programming THE JAVA PLATFORM

Lecture 1 Introduction to Android. App Development for Mobile Devices. App Development for Mobile Devices. Announcement.

Core Java Syllabus. Pre-requisite / Target Audience: C language skills (Good to Have)

Computer Programming-1 CSC 111. Chapter 1 : Introduction

Contents. iii Copyright 1998 Sun Microsystems, Inc. All Rights Reserved. Enterprise Services August 1998, Revision B

Introduction. Overview of the Course on Java. Overview of Part 1 of the Course

Full file at

Oracle Developer Studio 12.6

Lecture Notes on Programming Languages

Java. Classes 3/3/2014. Summary: Chapters 1 to 10. Java (2)

What is Java Platform?

Java Embedded on ARM

Java Internals. Frank Yellin Tim Lindholm JavaSoft

Operating- System Structures

The Java programming environment. The Java programming environment. Java: A tiny intro. Java features

History of Java. Java was originally developed by Sun Microsystems star:ng in This language was ini:ally called Oak Renamed Java in 1995

Multitiered Architectures & Cloud Services. Benoît Garbinato

Managed runtimes & garbage collection. CSE 6341 Some slides by Kathryn McKinley

Chapter 2: Operating-System Structures

Assoc. Prof. Dr. Marenglen Biba. (C) 2010 Pearson Education, Inc. All rights reserved.

Managed runtimes & garbage collection

SNS COLLEGE OF ENGINEERING, Coimbatore

COE318 Lecture Notes Week 3 (Week of Sept 17, 2012)

Java Performance: The Definitive Guide

Java SE 7 Programming

Transcription:

Advanced Object-Oriented Programming Introduction to OOP and Java Dr. Kulwadee Somboonviwat International College, KMITL kskulwad@kmitl.ac.th

Course Objectives Solidify object-oriented programming skills Study the Java Technology The Java Programming Language The Java Platform, Enterprise Edition (Java EE 7)

Key Topics covered in this course Fundamentals of Java Programming Object-oriented programming concepts GUI Programming Concurrency Java EE 7

Object-Oriented Programming Dominant programming paradigm these days A program is made of objects. Each object exposes specific functionality to the users encapsulates (hides) the implementation of its functionality

Traditional Procedural Programming 1970s: structured, procedural programming Programs = Algorithms + Data (Niklaus Wirth, 1975) First, we think about a set of procedures (algorithms) needed to solve our problem. Then, we find appropriate ways to store the data Used in C, Pascal, Basic, etc. Structured programming works well for small to medium sized problems

In procedural programming, - problem is decomposed into procedures - all procedures manipulate a set of global data procedure procedure procedure procedure procedure procedure Global Data Suppose that - your program has 2,000 procedures - a piece of data is in an incorrect state How are you going to find bugs in this situation? How many procedures you need to search for the culprit?

In object-oriented programming style, - your program consists of objects - each object has a specific set of attributes and methods method method method method method method Object data Object data Object data Suppose that - your program has 200 objects, and each object has 10 methods. - a piece of data of an object is in an incorrect state How are you going to find bugs in this situation? How many procedures you need to search for the culprit?

Java Technology The Java Programming Language The Java Platform Source: http://download.oracle.com/javase/tutorial/getstarted/intro/definition.html

Characteristics of the Java PL Simple Object oriented Distributed Multithreaded Dynamic Architecture neutral Portable High Performance Robust Secure

C++ versus Java Data types Features Java C++ Object allocation Object de-allocation Inheritance Binding Supports both primitive scalar types and classes Allocated from heap, accessed through reference variables (no pointers) Implicit (garbage collection) Single inheritance only (multiple inheritance is possible with interfaces) All binding of messages to methods are dynamic except in the case of methods that cannot be overridden Supports both primitive scalar types and classes Allocated from heap or stack, accessed through reference variables or pointers Explicit (delete operator) Single, Multiple inheritance Dynamic binding of messages to methods are optional (using the virtual keyword)

Java Technology The Java Programming Language The Java Platform Source: http://download.oracle.com/javase/tutorial/getstarted/intro/definition.html

Java As a Programming Platform A platform is the hardware or software environment in which a program runs. E.g. Windows, Linux, Solaris OS, and Mac OS Java is a software-only platform that runs on top of other hardware-based platforms. It consists of The Java Virtual Machine: a software-based processor that presents its own instruction set The Java Application Programming Interface (API) Source: http://download.oracle.com/javase/tutorial/getstarted/intro/definition.html

Different Editions of the Java Platform Java Platform, Standard Edition (Java SE): stand-alone programs that run on desktops. applets (programs that run in the context of a web browser) Java Platform, Enterprise Edition (Java EE): built on top of Java SE. enterprise-oriented applications and servlets (server programs that conform to Java EE s Servlet API). Java Platform, Micro Edition (Java ME): MIDlets (programs that run on mobile information devices) Xlets (which are programs that run on embedded devices)

Java Jargon

The Java API is a large collection of ready-made software components that provide many useful capabilities. It is grouped into libraries of related classes and interfaces; these libraries are known as packages Source: http://download.oracle.com/javase/tutorial/getstarted/intro/definition.html

Java Software Development Process Write the source code and save in files with.java extension Compile the source code into.class files using the javac compiler A.class file contains bytecodes (the machine language of the Java Virtual Machine (Java VM) Run the application (with an instance of the Java VM) using the java launcher tool. Source: http://download.oracle.com/javase/tutorial/getstarted/intro/definition.html

Java Program Execution The java tool loads and starts the VM, and passes the program s main classfile (.class) to the machine The VM uses classloader to load the classfile The VM s bytecode verifier checks that the classfile s bytecode is valid and does not compromise security If the bytecode has any problem, the verifier terminates the VM If all is well with the bytecode, the VM s interpreter interprets the bytecode one instruction at a time * Interpretation consists of identifying bytecode instructions, and executing equivalent native instructions (instructions understood by the physical processor )

$ javac HelloWorldApp.java $ java HelloWorldApp (1)Load the JVM (2)classloader loads HelloWorldApp.class (3)bytecode verifier check that the classfile is valid and secure (4)If all is well, the interpreter interpret the bytecode (5)A section of frequently executed bytecode will be compiled to native code by the JIT (Just In Time) compiler The Java platform provides an abstraction over the underlying hardware/os platform Portability: the same.class files can run unchanged on a variety of hardware platforms and operating systems

What can Java Technology Do? Development Tools: javac, java, javadoc Rich APIs Deployment Technologies: Web Start, Java Plug-In User Interface Toolkits Integration libraries: JDBC, JNDI, RMI