CS260 Intro to Java & Android 02.Java Technology

Similar documents
Advanced Object-Oriented Programming Introduction to OOP and Java

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

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

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

Inheritance. Benefits of Java s Inheritance. 1. Reusability of code 2. Code Sharing 3. Consistency in using an interface. Classes

Notes of the course - Advanced Programming. Barbara Russo

Chapter 2: Java OOP I

Introduction to Java Programming CPIT 202. WEWwwbvxnvbxmnhsgfkdjfcn

Certified Core Java Developer VS-1036

JVM interprets the Java bytecode, controls how it interacts with the operating system and manages memory.

MARS AREA SCHOOL DISTRICT Curriculum TECHNOLOGY EDUCATION

Zhifu Pei CSCI5448 Spring 2011 Prof. Kenneth M. Anderson

JAVA: A Primer. By: Amrita Rajagopal

Sri Vidya College of Engineering & Technology

Programming overview

Introduction to Java Programming

Contents. Figures. Tables. Examples. Foreword. Preface. 1 Basics of Java Programming 1. xix. xxi. xxiii. xxvii. xxix

Simple Java Programs. OOC 4 th Sem, B Div Prof. Mouna M. Naravani

Java Professional Certificate Day 1- Bridge Session

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

CHAPTER 1. Introduction to JAVA Programming

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

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

Core JAVA Training Syllabus FEE: RS. 8000/-

Table of Contents Fast Track to Java 8 EVALUATIONA COPY

CS 6456 OBJCET ORIENTED PROGRAMMING IV SEMESTER/EEE

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

Lecture 1: Introduction to Java

Chapter 1 Introduction to Java

Programming with Java

Developing Android applications in Windows

OVERRIDING. 7/11/2015 Budditha Hettige 82

Chapter 4 Java Language Fundamentals

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

Getting Started with Java. Atul Prakash

Java OOP (SE Tutorials: Learning the Java Language Trail : Object-Oriented Programming Concepts Lesson )

CS260 Intro to Java & Android 04.Android Intro

Welcome to Kmax Installing Kmax

Java for Programmers Course (equivalent to SL 275) 36 Contact Hours

Installation guide for Java. Step by Step Guide. A C A D G I L D Page 1

Chapter 1 Introduction to Java

History Introduction to Java Characteristics of Java Data types

Introduction to Java and OOP. Hendrik Speleers

4. Enhancing a class: Room. The Java platform. Java APIs. M1G413283: Introduction to Programming 2

엄현상 (Eom, Hyeonsang) School of Computer Science and Engineering Seoul National University COPYRIGHTS 2017 EOM, HYEONSANG ALL RIGHTS RESERVED

Lecture 02, Fall 2018 Friday September 7

CS335 Graphics and Multimedia

MODULE 1 JAVA PLATFORMS. Identifying Java Technology Product Groups

Getting Started with Eclipse/Java

Unit 4 - Inheritance, Packages & Interfaces

Software Development. Modular Design and Algorithm Analysis

SELF-STUDY. Glossary

Paytm Programming Sample paper: 1) A copy constructor is called. a. when an object is returned by value

Java Programming Language Mr.Rungrote Phonkam

Class 1: Homework. Intro to Computer Science CSCI-UA.0101 New York University Courant Institute of Mathematical Sciences Fall 2017

OBJECT ORIENTED PROGRAMMING

Getting Started With Java

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

The Impact of a Real-Time JVM on Middleware Performance: Lessons Learned from Implementing DDS on IBM s J9

Introduction to OOP Using Java Pearson Education, Inc. All rights reserved.

CS260 Intro to Java & Android 03.Java Language Basics

Java Puzzle Ball Nick Ristuccia

15CS45 : OBJECT ORIENTED CONCEPTS

The Computer System. Hardware = Physical Computer. Software = Computer Programs. People = End Users & Programmers. people

Objective-C: An Introduction (pt 1) Tennessee Valley Apple Developers Saturday CodeJam July 24, 2010 August 7, 2010

Fundamentals of Programming. By Budditha Hettige

Mobile Computing LECTURE # 2

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

Java SE 7 Programming

C++ Spring Break Packet 11 The Java Programming Language

Life Without NetBeans

Introduction to Programming Using Java (98-388)

CSE 421 Course Overview and Introduction to Java

CO Java SE 8: Fundamentals

TEMPO INSTALLATION I O A. Platform Independent Notes 1. Installing Tempo 3. Installing Tools for the Plugins 5. v0.2.

Introduction to Android

Programming II (CS300)

IT151: Introduction to Programming (java)

How to Install (then Test) the NetBeans Bundle

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

Crash Course Review Only. Please use online Jasmit Singh 2

CS200: Advanced OO in Java

Exploring the Java API, Packages & Collections

1z z Java SE 8 Programmer I

Introduction to Object- Oriented Programming

a guide to an object oriented programming language Niket Sheth JAVA

JAVA MOCK TEST JAVA MOCK TEST II

By: Abhishek Khare (SVIM - INDORE M.P)

Introduction... xv SECTION 1: DEVELOPING DESKTOP APPLICATIONS USING JAVA Chapter 1: Getting Started with Java... 1

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

GETTING STARTED. The longest journey begins with a single step. In this chapter, you will learn about: Compiling and Running a Java Program Page 2

iappliscan User Manual

Lesson 04: Our First Java Program (W01D4

CSCI 253. Outline. Background. George Blankenship 1

Index COPYRIGHTED MATERIAL

Manually Java 7 Update Bits Windows 7

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.

Short Questions. Instructor: Created by: Visit: 2/2/2018 OOP with JAVA. Muhammad Naveed

CompSci 125 Lecture 02

CS111: PROGRAMMING LANGUAGE II. Lecture 1: Introduction to classes

Transcription:

CS260 Intro to Java & Android 02.Java Technology CS260 - Intro to Java & Android 1

Getting Started: http://docs.oracle.com/javase/tutorial/getstarted/index.html Java Technology is: (a) a programming language and (b) a platform Java is a high-level programming language with the following characteristics: Architecture neutral Object-oriented Portable Multithreaded Dynamic CS260 - Intro to Java & Android 2

In Java: all source code is first written in plain text files with a.java extension the source files are compiled into.class files by the compiler (javac) a.class is not code native to your processor a.class contains bytecodes which is the machine language of the Java Virtual Machine (JVM) the java launcher (java) runs you re application with an instance of the JVM CS260 - Intro to Java & Android 3

Java bytecode can run on any JVM? CS260 - Intro to Java & Android 4

The Java Platform consists of two components: The JVM The Java Application Programming Interface (API) Java API - a large collection of ready-made software components Java API - grouped into libraries of related classes and interfaces; these libraries are known as packages CS260 - Intro to Java & Android 5

The Java Platform can be slower than native code. Advances in compiler and VM technologies are greatly improving performance. Example - Critical sections of bytecode can be compiled into native code and executed. CS260 - Intro to Java & Android 6

HelloUser for Microsoft Windows Download the most recent Java Development Kit (JDK) which includes: a Java Runtime Environment (JRE) http://www.oracle.com/technetwork/java/javase/downloads/index.html Q1: What is the JDK? A: Command-line programs used to: create programs compile programs run Java programs CS260 - Intro to Java & Android 7

P1: Go to the Start menu and Run the command cmd to bring up a shell or command window. Then enter the following command: > javac version javac 1.7.0_XX P2: Enter the following command: > java version java version "1.7.0_XX" Java(TM) SE Runtime Environment (build 1.7.0_XX) Java HotSpot(TM) 64-Bit Server VM (build XX, mixed mode) P3: Create a folder in your My Documents folder called CS260\Java CS260 - Intro to Java & Android 8

Learning the Java Language: http://docs.oracle.com/javase/tutorial/java/toc.html Read: 1. Object-Oriented Programming Concepts (ALL but What is an Interface ) 2. Language Basics (ALL) 3. Classes and Objects (ALL stopping at Nested Classes) 4. Numbers and Strings (ALL) CS260 - Intro to Java & Android 9

OOP Review Objects have two characteristics: (1) state and (2) behavior An object stores its state in fields and exposes its behavior through methods data encapsulation is the hiding of the internal state of an object and the requiring of interaction to be performed through an objects methods What is the state of a Rational number? What is the behavior or a Rational number? CS260 - Intro to Java & Android 10

class - blueprint from which objects are created CS260 - Intro to Java & Android 11

Inheritance - each class can inherit state and behavior from one superclass Each superclass can have unlimited subclasses CS260 - Intro to Java & Android 12

Interface - collection of abstract methods A class 1. implements an interface 2. inherits the abstract methods An interface is NOT a class CS260 - Intro to Java & Android 13

Interface similar to Class 1. can contain any number of methods 2. has.java extension 3. filename matches interface name 4..class contains bytecode Class different from Interface 1. cannot instantiate interface 2. cannot have constructors 3. all methods are abstract 4. cannot contain instance fields 5. not extended by a class 6. can extend multiple interfaces CS260 - Intro to Java & Android 14

package - is a namespace that organizes a set of related classes and interfaces Conceptually think of packages as different folders on your computer where related classes and interfaces reside. The Java API is broken up into many packages 1. java.lang - bundles the fundamental classes 2. java.io - classes for input and output The Java 7 Platform API Specification can be found at: http://docs.oracle.com/javase/7/docs/api/index.html CS260 - Intro to Java & Android 15