SlideShare a Scribd company logo
Object Oriented Concepts With
JAVA
Mehta Ishani
2nd M.E.(C.S.E)
Why OOP?
• Traditional Procedural-Oriented languages
– difficult to copy a function from one program and
reuse in another program because the the
function is reference the headers, global variables
and other functions.
(i.e. not well-encapsulated
as a self-contained reusable unit.)
– not suitable of high-level
abstraction for solving
real life problems.
Why OOP?
• Object-oriented programming (OOP)
languages
– class, which encapsulates both the static
attributes and dynamic behaviors (i.e. well-
encapsulated, easier to reuse)
– permit higher level of
abstraction for solving
real-life problems
Benefits of OOP
• Ease in software design
• Ease in software maintenance
• Reusable software
What is JAVA?
• programming language expressly designed for
use in the distributed environment of the
Internet
• Simple, Secure, Robust, Complete Object
Oriented and Platform Independent High level
Language.
• It is portable and Multi-thread technology
gives High performance.
JAVA
Hardware Platform
Java Platform
Software (OS) Platform
Operates and
Controls H/W
Environment
for Java
Development
JVM API
JAVA
How it Works:
JAVA
Java
Program
Virtual
Machine
Source code Bytecode
Java Compiler
Process of Compilation:
Java
Interpreter
Virtual
Machine
Real MachineBytecode
Object
• real word entity that has state and behavior
• contains data (instance variables)
representing its state, and instance methods,
which are the things it can do.
• instance of a class
Class
• Collection of objects
• template, blueprint or contract that defines
what an object’s data fields and methods will
be.
Abstraction
• Hiding internal details and showing
functionality
• In java, we use abstract class and interface to
achieve abstraction.
Encapsulation
• Binding (or wrapping) code and data together
into a single unit
• A java class
• Java bean
Inheritance
• When one object acquires all the properties
and behaviors of parent object
• provides code reusability.
• Used to achieve runtime polymorphism.
Inheritance
A
B
C
A B
C
A-1
A-2
B-1
B-2
AB
Multi-level Inheritance Multiple Inheritance
Multiple Multi-level Inheritance
Types of Inheritance:
Ploymorphism
• "Poly" means "many" and "morph" means
"form".
• When one task is performed by different
ways
Polymorphism
• same word or symbol to be interpreted
correctly in different situations based on the
context
• There are two types of polymorphism :
1.Compile-time polymorphism (Method
Overloading/Static)
2.Runtime Polymorphism (Method
Overriding/Dynamic)
Ploymorphism
Method Overloading:
having multiple methods with same name but
with different signature (number, type and
order of parameters).
Method Overriding:
When a subclass contains a method with the same
name and signature as in the super class then it is
called as method overriding.
Summery
• An object is an instance of a class.
• Using abstraction one can simulate real world objects.
• Abstraction provides advantage of code reuse
• Abstraction enables program open for extension
• Encapsulation provides the security that keeps data
and methods safe from inadvertent changes.
• Inheritance is parent-child relationship of class which is
mainly used for code reusability.
• Polymorphism definition is that Poly means many and
morphos means forms.
Object oriented concepts with java

More Related Content

PPSX
Java Object Oriented Programming
PPSX
Core java lessons
PPTX
Programming Fundamentals With OOPs Concepts (Java Examples Based)
PDF
JAVA Object Oriented Programming (OOP)
PPTX
Object+oriented+programming+in+java
PPT
OOP in Java
PPTX
Core java
PPTX
Object Oriented Programing JAVA presentaion
Java Object Oriented Programming
Core java lessons
Programming Fundamentals With OOPs Concepts (Java Examples Based)
JAVA Object Oriented Programming (OOP)
Object+oriented+programming+in+java
OOP in Java
Core java
Object Oriented Programing JAVA presentaion

What's hot (20)

PDF
Basic Java Programming
PPTX
Object oriented programming-with_java
PPSX
Short notes of oop with java
PDF
Cs8392 oops 5 units notes
PDF
OOPs Concepts - Android Programming
PPTX
Introduction to oop using java
DOCX
OBJECT ORIENTED ROGRAMMING With Question And Answer Full
PPTX
OOP Introduction with java programming language
PPTX
java training in jaipur|java training|core java training|java training compa...
PPTX
Java training in delhi
PPT
Oops ppt
PPTX
Core Java
PDF
Core Java
PPTX
Introduction to Java -unit-1
KEY
Practical OOP In Java
PPTX
PPTX
Introduction to oop
PPT
Java for the Beginners
PDF
Core Java Tutorial
PDF
Oops concepts || Object Oriented Programming Concepts in Java
Basic Java Programming
Object oriented programming-with_java
Short notes of oop with java
Cs8392 oops 5 units notes
OOPs Concepts - Android Programming
Introduction to oop using java
OBJECT ORIENTED ROGRAMMING With Question And Answer Full
OOP Introduction with java programming language
java training in jaipur|java training|core java training|java training compa...
Java training in delhi
Oops ppt
Core Java
Core Java
Introduction to Java -unit-1
Practical OOP In Java
Introduction to oop
Java for the Beginners
Core Java Tutorial
Oops concepts || Object Oriented Programming Concepts in Java
Ad

Similar to Object oriented concepts with java (20)

PPTX
PPTX
OOPS (Object Oriented Programming System) CONCEPTS
DOCX
Java oop concepts
PPTX
Introduction to OOP concepts
PPTX
Java and its concepts
PPTX
ITTutor Advanced Java (1).pptx
PPTX
Introduction to oop and java fundamentals
PPT
Java OOP s concepts and buzzwords
PPTX
Java Programming - UNIT - 1, Basics OOPS, Differences
PDF
Class notes(week 2) on basic concepts of oop-2
PPTX
Object Oriented Programming.pptx
PPTX
chapter 5 concepts of object oriented programming
DOCX
Class notes(week 2) on basic concepts of oop-2
PPTX
Features of Object Oriented Programming.pptx
PPTX
Shuvrojit Majumder . 25900120006 Object Oriented Programming (PCC-CS 503) ...
PPTX
Java OOP Concept
PPTX
Untitled presentation about object oriented.pptx
PDF
How to Learn Java Programming
PPTX
U1 JAVA.pptx
PPTX
oops concept in java | object oriented programming in java
OOPS (Object Oriented Programming System) CONCEPTS
Java oop concepts
Introduction to OOP concepts
Java and its concepts
ITTutor Advanced Java (1).pptx
Introduction to oop and java fundamentals
Java OOP s concepts and buzzwords
Java Programming - UNIT - 1, Basics OOPS, Differences
Class notes(week 2) on basic concepts of oop-2
Object Oriented Programming.pptx
chapter 5 concepts of object oriented programming
Class notes(week 2) on basic concepts of oop-2
Features of Object Oriented Programming.pptx
Shuvrojit Majumder . 25900120006 Object Oriented Programming (PCC-CS 503) ...
Java OOP Concept
Untitled presentation about object oriented.pptx
How to Learn Java Programming
U1 JAVA.pptx
oops concept in java | object oriented programming in java
Ad

More from ishmecse13 (14)

PDF
Search engine and web crawler
PPTX
Web services concepts, protocols and development
PDF
Web services concepts, protocols and development
PPTX
Web services
PPTX
Wap wml
PDF
Wap architecture and wml script
PPT
Solving travelling salesman problem using firefly algorithm
PPTX
Kerberos using public key cryptography
PPTX
Hierarchical clustering
PPT
File models and file accessing models
PDF
Case study on cyber crime
PPTX
Branch and bound technique
PDF
Branch and bound technique
PPTX
Cyber crime and cyber laws
Search engine and web crawler
Web services concepts, protocols and development
Web services concepts, protocols and development
Web services
Wap wml
Wap architecture and wml script
Solving travelling salesman problem using firefly algorithm
Kerberos using public key cryptography
Hierarchical clustering
File models and file accessing models
Case study on cyber crime
Branch and bound technique
Branch and bound technique
Cyber crime and cyber laws

Recently uploaded (20)

PDF
PPT on Performance Review to get promotions
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPT
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
PPTX
additive manufacturing of ss316l using mig welding
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PPTX
web development for engineering and engineering
PDF
R24 SURVEYING LAB MANUAL for civil enggi
DOCX
573137875-Attendance-Management-System-original
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
CYBER-CRIMES AND SECURITY A guide to understanding
PDF
composite construction of structures.pdf
PDF
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PPTX
CH1 Production IntroductoryConcepts.pptx
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PPTX
Geodesy 1.pptx...............................................
PPT on Performance Review to get promotions
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
additive manufacturing of ss316l using mig welding
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
web development for engineering and engineering
R24 SURVEYING LAB MANUAL for civil enggi
573137875-Attendance-Management-System-original
Internet of Things (IOT) - A guide to understanding
CYBER-CRIMES AND SECURITY A guide to understanding
composite construction of structures.pdf
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
CH1 Production IntroductoryConcepts.pptx
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
Geodesy 1.pptx...............................................

Object oriented concepts with java

  • 1. Object Oriented Concepts With JAVA Mehta Ishani 2nd M.E.(C.S.E)
  • 2. Why OOP? • Traditional Procedural-Oriented languages – difficult to copy a function from one program and reuse in another program because the the function is reference the headers, global variables and other functions. (i.e. not well-encapsulated as a self-contained reusable unit.) – not suitable of high-level abstraction for solving real life problems.
  • 3. Why OOP? • Object-oriented programming (OOP) languages – class, which encapsulates both the static attributes and dynamic behaviors (i.e. well- encapsulated, easier to reuse) – permit higher level of abstraction for solving real-life problems
  • 4. Benefits of OOP • Ease in software design • Ease in software maintenance • Reusable software
  • 5. What is JAVA? • programming language expressly designed for use in the distributed environment of the Internet • Simple, Secure, Robust, Complete Object Oriented and Platform Independent High level Language. • It is portable and Multi-thread technology gives High performance.
  • 6. JAVA Hardware Platform Java Platform Software (OS) Platform Operates and Controls H/W Environment for Java Development JVM API
  • 8. JAVA Java Program Virtual Machine Source code Bytecode Java Compiler Process of Compilation: Java Interpreter Virtual Machine Real MachineBytecode
  • 9. Object • real word entity that has state and behavior • contains data (instance variables) representing its state, and instance methods, which are the things it can do. • instance of a class
  • 10. Class • Collection of objects • template, blueprint or contract that defines what an object’s data fields and methods will be.
  • 11. Abstraction • Hiding internal details and showing functionality • In java, we use abstract class and interface to achieve abstraction.
  • 12. Encapsulation • Binding (or wrapping) code and data together into a single unit • A java class • Java bean
  • 13. Inheritance • When one object acquires all the properties and behaviors of parent object • provides code reusability. • Used to achieve runtime polymorphism.
  • 14. Inheritance A B C A B C A-1 A-2 B-1 B-2 AB Multi-level Inheritance Multiple Inheritance Multiple Multi-level Inheritance Types of Inheritance:
  • 15. Ploymorphism • "Poly" means "many" and "morph" means "form". • When one task is performed by different ways
  • 16. Polymorphism • same word or symbol to be interpreted correctly in different situations based on the context • There are two types of polymorphism : 1.Compile-time polymorphism (Method Overloading/Static) 2.Runtime Polymorphism (Method Overriding/Dynamic)
  • 17. Ploymorphism Method Overloading: having multiple methods with same name but with different signature (number, type and order of parameters). Method Overriding: When a subclass contains a method with the same name and signature as in the super class then it is called as method overriding.
  • 18. Summery • An object is an instance of a class. • Using abstraction one can simulate real world objects. • Abstraction provides advantage of code reuse • Abstraction enables program open for extension • Encapsulation provides the security that keeps data and methods safe from inadvertent changes. • Inheritance is parent-child relationship of class which is mainly used for code reusability. • Polymorphism definition is that Poly means many and morphos means forms.