Вы находитесь на странице: 1из 14

Introduction to the subject

• Module 1 – 2: - Introduction to Java


- Variables & Operators
• Module 3 - 4: - Decision-Making & Iterations
- Introduction to Classes
• Module 5 - 6: - Arrays/Strings/Other string classes
- Packages, Access Modifiers
• Module 7 - 8: - Inheritance and Interfaces
- More on Classes
• Module 9: - Exceptions
- Overview
Learn Java by Example - Module 1-2 1/13
Module 1 -
Introduction to Java
Introduction to Java

• Classes and Objects

• Getting started with Java

• Introduction to JDK

• Writing a Java program

• NetBeans IDE Overwiew

• Using comment in Java

Learn Java by Example - Module 1-2 3/19


3
Class and Object

• Describe real-world entities as objects

• Describe a software object

• Describe and explain the structure of a class

• Compare classes and objects

Learn Java by Example - Module 1-2 4/13


Class & Objects
• Object is the presentation of real world entities.
• The two most important elements of object in real
world are characteristics and actions
Object (Real world) Software Object
Characteristics (properties) State – Attributes – Variables - Fields

Actions Behavior – Method - Functions

• Class is a template defines the outline of state and


behavior for all object belonging to that class
• All instances of the class, called objects, will have
common state and behavior
Learn Java by Example - Module 1-2 5/13
Class && Object: Compare

Learn Java by Example - Module 1-2 6/13


6
Getting started with Java

• Identify the evolution stages of Java

• State the components of the Java platform

• List the features of Java as programming

language

Learn Java by Example - Module 1-2 7/13


The evolution stages of Java
1. Embedded Systems
(1991 – 1994)

2. A client – side Wonder


(1995 – 1997)

3. Moved into the


Middle – tier
(1997 – to present)

4. Future:
may gain more success
Learn Java by Example - Module 1-2 8/19
8
Java platform

(java.exe)

Learn Java by Example - Module 1-2 9/19


9
Java – Programming language
• Object – oriented: The elements are present can only
be accessed through classes and objects.
• Platform – independent: The ability of a program to
run on any machine regardless of underlying platform
• Robust: Java requires all data to be declared explicitly
• Secure: Provides a secure environment and several
layers of security controls
• Distributed: To develop application portable across
multiply platform.
• Multi-threaded: Java provides for multi-threading to
perform many task simultaneously
Learn Java by Example - Module 1-2 10/13
Introduction JDK
• Explain JDK and its tools
– javac (Java compiler)
– java (Java interpreter)
• Configure JDK
– Path
– Classpath
• Writing a java simple program
– Writing
– Compile and execute
Learn Java by Example - Module 1-2 11/13
NetBeans IDE Overview

• Identify the benefits of NetBeans Integrated


Development Environment (IDE)
• Identify the elements of NetBeans IDE

• List the steps to create a Java program using


NetBeans IDE

Learn Java by Example - Module 1-2 12/13


Summary - Module 1
• Classes and Objects
• Introduction to Java
• Introduction to JDK
• Writing a Java program
• NetBeans IDE
• Using comment in Java

Learn Java by Example - Module 1-2 13/13


Homework
• 1) Đọc lại và gõ ví dụ Module 1
• 2) Làm WorkShop Module 1
• 3) Gừi Assignment -1
• 4) Đọc trước và gõ ví dụ Module 2
• 5) Khuyến khích: Đọc và gõ ví dụ Module 3

Learn Java by Example - Module 1-2 14/13

Вам также может понравиться