SlideShare una empresa de Scribd logo
1 de 18
OBJECT-ORIENTED PROGRAMMING
INTRODUCTION Languages that support OOP are firmly entrenched in the mainstream. From COBOL to LISP c++, Ada 95, and CLOS, an OOP version of LISP.  C++ and Ada 95 support procedural- and data-oriented programming, CLOS also supports funcitonal programming. Some of the newer languages that were designed to support object-oriented programming do not support other programming paradigms, but still employ some of the basic structures and have the appearance of the older imperative languages. Among these are Eiffel and Java. Smalltalk was the first language to offer complete support for object-oriented programming. This is inheritance, which is at the center of object-oriented programming and the languages that support it.
INTRODUCTION   The concept of  object-oriented programming  has its roots in SIMULA 67 but was not fully developed until the evolution of Smalltalk resulted in producing Smalltalk 80 (in1980, of course).  Three key languages: -abstract data types -inheritance -a particular kind of dynamic binding Procedure-oriented programming focuses on subprograms and subprogram libraries. Data-oriented programming focuses on abstract data types. The Sorting process is enacted by calling that operation on the specific array object. The data-oriented programming paradigm was popular in the 1980s, and it served by the data abstraction facilities of Modula-2, Ada, and several more recent languages.  Object-based  languages are the languages that support data-oriented programming. Object-Oriented Programming
INHERITANCE ,[object Object]
Inheritance offers a solution to both modification problem posed by abstract data type and the program organization problem.  If a new abstract data type can inherit the data and functionality of some existing type, and is also allowed to modify some of those  Entities and add new entities, reuse is greatly facilitated without changes to the reused data type. The abstract data types in OOP, following the lead of SIMULA 67, are usually called  classes . As with instances of abstract data types, Class instances are called  objects . A class that is defined through Inheritance from another class is a  derived class  or  subclass . A class from which the new class is derived is its  parent class  or  superclass . The sub-programs that define the operations on objects of a class are  Called  methods . The calls to methods are often called  messages .  The entire collection of methods of an objects is called the  message protocol ,  or message interface , of the object.
A modified method has the same name. and often the same protocol, As the one of which it is a modification. The new method is said to override the inherited version, which is then called an overriden method. The most common purpose of an overriding method Is to provide an operation that is specific for objects of the derived class but is not appropriate for objects of the parent class. classes can have two kinds of methods and variables. The most commonly used methods and variables are called instance methods And variables. Every object of a class has its own set of instance variables, which store the objects state. The only difference  between two objects of the same class is the state of their instance variables. Instance methods operate only on the objects of the class. Class variables belong to the class, rather than its object, so there only one copy for the class.  Class methods can perform operations on the class, and possibly also on the objects of the class.
If a new class is a subclass of a single parent class, then the  Derivation process is called single inheritance. If a class has more than one parent class, the process is called multiple inheritance. When a number of classes are related through single inheritance, their relationships to each other can be shown in a derivation tree.  The class relationship in a multiple inheritance can be  shown in a derivation graph.  One disadvantage of inheritance as a means Of increasing the possibility of reuse is that it creates a dependency Among the classes in an inheritance hierarchy.
Polymorphism and Dynamic Binding 3 rd  characteristics of OOP language is a kind of polymorphism  provided by the dynamic binding of messages to method definitions. This is supported by allowing one to define polymorphic  variables of the type of the parent class that are also able to reference objects of any  of the subclass of that class. The parent class can define a method that is overridden by its subclass. Virtual method , any class that includes at least one virtual method is called a  virtual class.  Such as class cannot be instantiated because not all of its methods have bodies.
Computing with an OOP language ,[object Object],[object Object],[object Object],[object Object]
Design Issues for Object-Oriented Languages ,[object Object],[object Object],[object Object]
On the other hand, keeping the implementation part of the parent class hidden from the subclasses can cause inefficiencies in the execution of the instances of those subclasses. This can be caused by the difference in efficiency of having direct access to data structures versus requiring access through the operations defined in the parent class. However, if the language designer has chosen interface inheritance, this code would look something like   int  second ( )  {   int  temp = top ( ) ;   pop ( ) ;   int  temp_result = top ( ) ;   push (temp) ;   return  temp_result; } This is clearly a slower process than the direct access to the second element from the top of the stack. The best solution for the language designer is to provide both implementation and interface inheritance options to the software designer and let him or her decide, on a case-by-case basis, which version is better.
Type Checking and Polymorphism ,[object Object],[object Object],[object Object],[object Object]
Allocation and Deallocation of Objects ,[object Object],[object Object],[object Object]
Dynamic and Static Binding ,[object Object]
Support for OOP in java ,[object Object],[object Object]
Inheritance   ,[object Object],[object Object],[object Object],[object Object]
Encapsulation ,[object Object],[object Object],[object Object],[object Object]
Evaluation ,[object Object]

Más contenido relacionado

La actualidad más candente

Object Oriented Language
Object Oriented LanguageObject Oriented Language
Object Oriented Languagedheva B
 
A novel approach for clone group mapping
A novel approach for clone group mappingA novel approach for clone group mapping
A novel approach for clone group mappingijseajournal
 
Type variability and completeness of interfaces in java applications
Type variability and completeness of interfaces in java applicationsType variability and completeness of interfaces in java applications
Type variability and completeness of interfaces in java applicationsijseajournal
 
Class Diagram Extraction from Textual Requirements Using NLP Techniques
Class Diagram Extraction from Textual Requirements Using NLP TechniquesClass Diagram Extraction from Textual Requirements Using NLP Techniques
Class Diagram Extraction from Textual Requirements Using NLP Techniquesiosrjce
 
principle of oop’s in cpp
principle of oop’s in cppprinciple of oop’s in cpp
principle of oop’s in cppgourav kottawar
 
12 object oriented programming
12 object oriented programming12 object oriented programming
12 object oriented programmingjigeno
 
Oops concept in c++ unit 3 -topic 4
Oops concept in c++ unit 3 -topic 4Oops concept in c++ unit 3 -topic 4
Oops concept in c++ unit 3 -topic 4MOHIT TOMAR
 
Polymorphism and interface in vb.net
Polymorphism and interface in vb.netPolymorphism and interface in vb.net
Polymorphism and interface in vb.netKarthigaGunasekaran1
 
Object oriented basics
Object oriented basicsObject oriented basics
Object oriented basicsvamshimahi
 
Object oriented programming
Object oriented programmingObject oriented programming
Object oriented programmingAmit Soni (CTFL)
 

La actualidad más candente (20)

Object Oriented Language
Object Oriented LanguageObject Oriented Language
Object Oriented Language
 
General OOP Concepts
General OOP ConceptsGeneral OOP Concepts
General OOP Concepts
 
A novel approach for clone group mapping
A novel approach for clone group mappingA novel approach for clone group mapping
A novel approach for clone group mapping
 
concept of oops
concept of oopsconcept of oops
concept of oops
 
Type variability and completeness of interfaces in java applications
Type variability and completeness of interfaces in java applicationsType variability and completeness of interfaces in java applications
Type variability and completeness of interfaces in java applications
 
Class Diagram Extraction from Textual Requirements Using NLP Techniques
Class Diagram Extraction from Textual Requirements Using NLP TechniquesClass Diagram Extraction from Textual Requirements Using NLP Techniques
Class Diagram Extraction from Textual Requirements Using NLP Techniques
 
OOPS_Unit_1
OOPS_Unit_1OOPS_Unit_1
OOPS_Unit_1
 
Icsme16.ppt
Icsme16.pptIcsme16.ppt
Icsme16.ppt
 
Object Oriented Programming
Object Oriented ProgrammingObject Oriented Programming
Object Oriented Programming
 
Lecture 12
Lecture 12Lecture 12
Lecture 12
 
principle of oop’s in cpp
principle of oop’s in cppprinciple of oop’s in cpp
principle of oop’s in cpp
 
12 object oriented programming
12 object oriented programming12 object oriented programming
12 object oriented programming
 
Concepts of oops
Concepts of oopsConcepts of oops
Concepts of oops
 
Oops concept in c++ unit 3 -topic 4
Oops concept in c++ unit 3 -topic 4Oops concept in c++ unit 3 -topic 4
Oops concept in c++ unit 3 -topic 4
 
Object oriented programming
Object oriented programmingObject oriented programming
Object oriented programming
 
General oops concepts
General oops conceptsGeneral oops concepts
General oops concepts
 
Lecture 8
Lecture 8Lecture 8
Lecture 8
 
Polymorphism and interface in vb.net
Polymorphism and interface in vb.netPolymorphism and interface in vb.net
Polymorphism and interface in vb.net
 
Object oriented basics
Object oriented basicsObject oriented basics
Object oriented basics
 
Object oriented programming
Object oriented programmingObject oriented programming
Object oriented programming
 

Destacado

GNAT GPL For Mindstorms
GNAT GPL For MindstormsGNAT GPL For Mindstorms
GNAT GPL For MindstormsAdaCore
 
Euclid open network - Project Work at #sds2013
Euclid open network - Project Work at #sds2013Euclid open network - Project Work at #sds2013
Euclid open network - Project Work at #sds2013Guglielmo Apolloni
 
Rails Girls Cluj: Programming in the real world
Rails Girls Cluj: Programming in the real worldRails Girls Cluj: Programming in the real world
Rails Girls Cluj: Programming in the real worldMircea Mare
 
Ada Lovelace Day - 200 anos
Ada Lovelace Day - 200 anosAda Lovelace Day - 200 anos
Ada Lovelace Day - 200 anosTania Andrea
 
Entrevista exclusiva tim berners lee
Entrevista exclusiva tim berners leeEntrevista exclusiva tim berners lee
Entrevista exclusiva tim berners leeAlexandre Grolla
 
GNAT Pro User Day: New and Upcoming Developments in the AdaCore Technology
GNAT Pro User Day: New and Upcoming Developments in the AdaCore TechnologyGNAT Pro User Day: New and Upcoming Developments in the AdaCore Technology
GNAT Pro User Day: New and Upcoming Developments in the AdaCore TechnologyAdaCore
 
GNAT Pro User Day: Ada Factory
GNAT Pro User Day: Ada FactoryGNAT Pro User Day: Ada Factory
GNAT Pro User Day: Ada FactoryAdaCore
 
GNAT Pro User Day: GNATdoc: Automatic Documentation Generator
GNAT Pro User Day: GNATdoc: Automatic Documentation GeneratorGNAT Pro User Day: GNATdoc: Automatic Documentation Generator
GNAT Pro User Day: GNATdoc: Automatic Documentation GeneratorAdaCore
 
GNAT Pro User Day: Ada at Ansaldo STS
GNAT Pro User Day: Ada at Ansaldo STSGNAT Pro User Day: Ada at Ansaldo STS
GNAT Pro User Day: Ada at Ansaldo STSAdaCore
 
ADA programming language
ADA programming languageADA programming language
ADA programming languageAisha Kalsoom
 
Ada Seminar — An Introduction to Ada
Ada Seminar — An Introduction to AdaAda Seminar — An Introduction to Ada
Ada Seminar — An Introduction to AdaAdrian Hoe
 
Ada 2012
Ada 2012Ada 2012
Ada 2012AdaCore
 
Euclid and his contribution in development of math
Euclid and his contribution in development of mathEuclid and his contribution in development of math
Euclid and his contribution in development of mathAkshay Kumar
 
Evolution of Programming Languages
Evolution of Programming LanguagesEvolution of Programming Languages
Evolution of Programming LanguagesSayanee Basu
 

Destacado (18)

GNAT GPL For Mindstorms
GNAT GPL For MindstormsGNAT GPL For Mindstorms
GNAT GPL For Mindstorms
 
Euclid open network - Project Work at #sds2013
Euclid open network - Project Work at #sds2013Euclid open network - Project Work at #sds2013
Euclid open network - Project Work at #sds2013
 
Ada 95 - Programming in the large
Ada 95 - Programming in the largeAda 95 - Programming in the large
Ada 95 - Programming in the large
 
Rails Girls Cluj: Programming in the real world
Rails Girls Cluj: Programming in the real worldRails Girls Cluj: Programming in the real world
Rails Girls Cluj: Programming in the real world
 
Ada Lovelace Day - 200 anos
Ada Lovelace Day - 200 anosAda Lovelace Day - 200 anos
Ada Lovelace Day - 200 anos
 
Entrevista exclusiva tim berners lee
Entrevista exclusiva tim berners leeEntrevista exclusiva tim berners lee
Entrevista exclusiva tim berners lee
 
GNAT Pro User Day: New and Upcoming Developments in the AdaCore Technology
GNAT Pro User Day: New and Upcoming Developments in the AdaCore TechnologyGNAT Pro User Day: New and Upcoming Developments in the AdaCore Technology
GNAT Pro User Day: New and Upcoming Developments in the AdaCore Technology
 
GNAT Pro User Day: Ada Factory
GNAT Pro User Day: Ada FactoryGNAT Pro User Day: Ada Factory
GNAT Pro User Day: Ada Factory
 
GNAT Pro User Day: GNATdoc: Automatic Documentation Generator
GNAT Pro User Day: GNATdoc: Automatic Documentation GeneratorGNAT Pro User Day: GNATdoc: Automatic Documentation Generator
GNAT Pro User Day: GNATdoc: Automatic Documentation Generator
 
GNAT Pro User Day: Ada at Ansaldo STS
GNAT Pro User Day: Ada at Ansaldo STSGNAT Pro User Day: Ada at Ansaldo STS
GNAT Pro User Day: Ada at Ansaldo STS
 
ADA programming language
ADA programming languageADA programming language
ADA programming language
 
Ada Seminar — An Introduction to Ada
Ada Seminar — An Introduction to AdaAda Seminar — An Introduction to Ada
Ada Seminar — An Introduction to Ada
 
Ada 2012
Ada 2012Ada 2012
Ada 2012
 
Euclid and his contribution in development of math
Euclid and his contribution in development of mathEuclid and his contribution in development of math
Euclid and his contribution in development of math
 
High performance fibres
High performance fibresHigh performance fibres
High performance fibres
 
Evolution of Programming Languages
Evolution of Programming LanguagesEvolution of Programming Languages
Evolution of Programming Languages
 
Ada 2012
Ada 2012Ada 2012
Ada 2012
 
Euclid project
Euclid projectEuclid project
Euclid project
 

Similar a Oop

Oop by edgar lagman jr
Oop by edgar lagman jr Oop by edgar lagman jr
Oop by edgar lagman jr Jun-jun Lagman
 
oopsinvb-191021101327.pdf
oopsinvb-191021101327.pdfoopsinvb-191021101327.pdf
oopsinvb-191021101327.pdfJP Chicano
 
Top 30 Technical interview questions
Top 30 Technical interview questionsTop 30 Technical interview questions
Top 30 Technical interview questionsSohailSaifi15
 
Oops concepts || Object Oriented Programming Concepts in Java
Oops concepts || Object Oriented Programming Concepts in JavaOops concepts || Object Oriented Programming Concepts in Java
Oops concepts || Object Oriented Programming Concepts in JavaMadishetty Prathibha
 
Software_Engineering_Presentation (1).pptx
Software_Engineering_Presentation (1).pptxSoftware_Engineering_Presentation (1).pptx
Software_Engineering_Presentation (1).pptxArifaMehreen1
 
OOP Introduction with java programming language
OOP Introduction with java programming languageOOP Introduction with java programming language
OOP Introduction with java programming languageMd.Al-imran Roton
 
Object oriented programming in python
Object oriented programming in pythonObject oriented programming in python
Object oriented programming in pythonnitamhaske
 
What is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxWhat is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxhreempandya
 

Similar a Oop (20)

Oop by edgar lagman jr
Oop by edgar lagman jr Oop by edgar lagman jr
Oop by edgar lagman jr
 
oopsinvb-191021101327.pdf
oopsinvb-191021101327.pdfoopsinvb-191021101327.pdf
oopsinvb-191021101327.pdf
 
Oops in vb
Oops in vbOops in vb
Oops in vb
 
Chapter1 introduction
Chapter1 introductionChapter1 introduction
Chapter1 introduction
 
chapter - 1.ppt
chapter - 1.pptchapter - 1.ppt
chapter - 1.ppt
 
OOP
OOPOOP
OOP
 
Unit 1 Java
Unit 1 JavaUnit 1 Java
Unit 1 Java
 
MCA NOTES.pdf
MCA NOTES.pdfMCA NOTES.pdf
MCA NOTES.pdf
 
Top 30 Technical interview questions
Top 30 Technical interview questionsTop 30 Technical interview questions
Top 30 Technical interview questions
 
INTRODUCTION TO JAVA
INTRODUCTION TO JAVAINTRODUCTION TO JAVA
INTRODUCTION TO JAVA
 
Oops concepts || Object Oriented Programming Concepts in Java
Oops concepts || Object Oriented Programming Concepts in JavaOops concepts || Object Oriented Programming Concepts in Java
Oops concepts || Object Oriented Programming Concepts in Java
 
Software_Engineering_Presentation (1).pptx
Software_Engineering_Presentation (1).pptxSoftware_Engineering_Presentation (1).pptx
Software_Engineering_Presentation (1).pptx
 
OOP Introduction with java programming language
OOP Introduction with java programming languageOOP Introduction with java programming language
OOP Introduction with java programming language
 
Oop basic concepts
Oop basic conceptsOop basic concepts
Oop basic concepts
 
Object oriented programming in python
Object oriented programming in pythonObject oriented programming in python
Object oriented programming in python
 
Oops concepts
Oops conceptsOops concepts
Oops concepts
 
JAVA-PPT'S.pdf
JAVA-PPT'S.pdfJAVA-PPT'S.pdf
JAVA-PPT'S.pdf
 
Unit 1 OOSE
Unit 1 OOSE Unit 1 OOSE
Unit 1 OOSE
 
What is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxWhat is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptx
 
Mcs024
Mcs024Mcs024
Mcs024
 

Último

ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
Science 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxScience 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxMaryGraceBautista27
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxCarlos105
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfphamnguyenenglishnb
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatYousafMalik24
 
Culture Uniformity or Diversity IN SOCIOLOGY.pptx
Culture Uniformity or Diversity IN SOCIOLOGY.pptxCulture Uniformity or Diversity IN SOCIOLOGY.pptx
Culture Uniformity or Diversity IN SOCIOLOGY.pptxPoojaSen20
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designMIPLM
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPCeline George
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17Celine George
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)lakshayb543
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Celine George
 
Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)cama23
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 

Último (20)

ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
Science 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxScience 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptx
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptxYOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice great
 
Culture Uniformity or Diversity IN SOCIOLOGY.pptx
Culture Uniformity or Diversity IN SOCIOLOGY.pptxCulture Uniformity or Diversity IN SOCIOLOGY.pptx
Culture Uniformity or Diversity IN SOCIOLOGY.pptx
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-design
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERP
 
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptxYOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
 
Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 

Oop

  • 2. INTRODUCTION Languages that support OOP are firmly entrenched in the mainstream. From COBOL to LISP c++, Ada 95, and CLOS, an OOP version of LISP. C++ and Ada 95 support procedural- and data-oriented programming, CLOS also supports funcitonal programming. Some of the newer languages that were designed to support object-oriented programming do not support other programming paradigms, but still employ some of the basic structures and have the appearance of the older imperative languages. Among these are Eiffel and Java. Smalltalk was the first language to offer complete support for object-oriented programming. This is inheritance, which is at the center of object-oriented programming and the languages that support it.
  • 3. INTRODUCTION The concept of object-oriented programming has its roots in SIMULA 67 but was not fully developed until the evolution of Smalltalk resulted in producing Smalltalk 80 (in1980, of course). Three key languages: -abstract data types -inheritance -a particular kind of dynamic binding Procedure-oriented programming focuses on subprograms and subprogram libraries. Data-oriented programming focuses on abstract data types. The Sorting process is enacted by calling that operation on the specific array object. The data-oriented programming paradigm was popular in the 1980s, and it served by the data abstraction facilities of Modula-2, Ada, and several more recent languages. Object-based languages are the languages that support data-oriented programming. Object-Oriented Programming
  • 4.
  • 5. Inheritance offers a solution to both modification problem posed by abstract data type and the program organization problem. If a new abstract data type can inherit the data and functionality of some existing type, and is also allowed to modify some of those Entities and add new entities, reuse is greatly facilitated without changes to the reused data type. The abstract data types in OOP, following the lead of SIMULA 67, are usually called classes . As with instances of abstract data types, Class instances are called objects . A class that is defined through Inheritance from another class is a derived class or subclass . A class from which the new class is derived is its parent class or superclass . The sub-programs that define the operations on objects of a class are Called methods . The calls to methods are often called messages . The entire collection of methods of an objects is called the message protocol , or message interface , of the object.
  • 6. A modified method has the same name. and often the same protocol, As the one of which it is a modification. The new method is said to override the inherited version, which is then called an overriden method. The most common purpose of an overriding method Is to provide an operation that is specific for objects of the derived class but is not appropriate for objects of the parent class. classes can have two kinds of methods and variables. The most commonly used methods and variables are called instance methods And variables. Every object of a class has its own set of instance variables, which store the objects state. The only difference between two objects of the same class is the state of their instance variables. Instance methods operate only on the objects of the class. Class variables belong to the class, rather than its object, so there only one copy for the class. Class methods can perform operations on the class, and possibly also on the objects of the class.
  • 7. If a new class is a subclass of a single parent class, then the Derivation process is called single inheritance. If a class has more than one parent class, the process is called multiple inheritance. When a number of classes are related through single inheritance, their relationships to each other can be shown in a derivation tree. The class relationship in a multiple inheritance can be shown in a derivation graph. One disadvantage of inheritance as a means Of increasing the possibility of reuse is that it creates a dependency Among the classes in an inheritance hierarchy.
  • 8. Polymorphism and Dynamic Binding 3 rd characteristics of OOP language is a kind of polymorphism provided by the dynamic binding of messages to method definitions. This is supported by allowing one to define polymorphic variables of the type of the parent class that are also able to reference objects of any of the subclass of that class. The parent class can define a method that is overridden by its subclass. Virtual method , any class that includes at least one virtual method is called a virtual class. Such as class cannot be instantiated because not all of its methods have bodies.
  • 9.
  • 10.
  • 11. On the other hand, keeping the implementation part of the parent class hidden from the subclasses can cause inefficiencies in the execution of the instances of those subclasses. This can be caused by the difference in efficiency of having direct access to data structures versus requiring access through the operations defined in the parent class. However, if the language designer has chosen interface inheritance, this code would look something like int second ( ) { int temp = top ( ) ; pop ( ) ; int temp_result = top ( ) ; push (temp) ; return temp_result; } This is clearly a slower process than the direct access to the second element from the top of the stack. The best solution for the language designer is to provide both implementation and interface inheritance options to the software designer and let him or her decide, on a case-by-case basis, which version is better.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16.
  • 17.
  • 18.