By Rajanikanth B www.btechsmartclass.com OOP Concepts By Rajanikanth B www.btechsmartclass.com.

Slides:



Advertisements
Similar presentations
Object Oriented Programming
Advertisements

Introduction to classes Sangeetha Parthasarathy 06/11/2001.
INHERITANCE BASICS Reusability is achieved by INHERITANCE
C++ Classes & Data Abstraction
Department of computer science N. Harika. Inheritance Inheritance is a fundamental Object Oriented concept A class can be defined as a "subclass" of another.
Object Oriented Programming Inheritance and Polymorphism Dr. Mike Spann
ACM/JETT Workshop - August 4-5, :Inheritance and Interfaces.
1 Using Classes and Working With Class Interfaces November 20, 2002 CSE103 - Penn State University Prepared by Doug Hogan.
Object Oriented Programming | Website for students | VTU NOTES.
More about classes and objects Classes in Visual Basic.NET.
Inheritance The objectives of this chapter are: To explore the concept and implications of inheritance Polymorphism To define the syntax of inheritance.
OOP in Java Nelson Padua-Perez Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
ECE122 L6: Problem Definition and Implementation February 15, 2007 ECE 122 Engineering Problem Solving with Java Lecture 6 Problem Definition and Implementation.
OOP in Java Fawzi Emad Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
Introduction To OOP 1.0 Fundamentals Of Java Programming Language 2.0 Exception Handling 3.0 Classes, Inheritance And Polymorphism
Object Oriented Programming. Problem Description “ …customers are allowed to have different types of bank accounts, deposit money, withdraw money and.
Chapter 10: Inheritance 1. Inheritance  Inheritance allows a software developer to derive a new class from an existing one  The existing class is called.
Programming Languages and Paradigms Object-Oriented Programming.
CSM-Java Programming-I Spring,2005 Introduction to Objects and Classes Lesson - 1.
Module 7: Essentials of Object-Oriented Programming.
CSM-Java Programming-I Spring,2005 Objects and Classes Overview Lesson - 1.
Module 7: Object-Oriented Programming in Visual Basic .NET
OBJECT ORIENTED PROGRAMMING CONCEPTS ISC 560. Object-oriented Concepts  Objects – things names with nouns  Classes – classifications (groups) of similar.
Introduction to Object Oriented Programming. Object Oriented Programming Technique used to develop programs revolving around the real world entities In.
Introduction to Java Prepared by: Ahmed Hefny. Outline Classes Access Levels Member Initialization Inheritance and Polymorphism Interfaces Inner Classes.
A class in Java is a software construct that includes fields (also called data fields or class scope variables) to provide data specification, and methods.
Chapter 7 Objects and Classes 1 Fall 2012 CS2302: Programming Principles.
ACO 101: Introduction to Computer Science Anatomy Part 2: Methods.
Encapsulation, Inheritance & Polymorphism. OOP Properties Encapsulation ­The process of creating programs so that information within a class is not accessible.
1 OOP - An Introduction ISQS 6337 John R. Durrett.
نظام المحاضرات الالكترونينظام المحاضرات الالكتروني Introduction to Object Oriented Programming (OOP) Object Oriented programming is method of programming.
CITA 342 Section 1 Object Oriented Programming (OOP)
© 2007 Lawrenceville Press Slide 1 Chapter 9 Inheritance  One class is an extension of another.  Allows a class to define a specialized type of an existing.
Classes, Interfaces and Packages
Computer Programming 2 Lecture 8: Object Oriented Programming Creating Classes & Objects Prepared & Presented by: Mahmoud Rafeek Alfarra MINISTRY OF EDUCATION.
Object Oriented Programming Session # 03.  Abstraction: Process of forming of general and relevant information from a complex scenarios.  Encapsulation:
Basic Concepts of OOP.  Object-Oriented Programming (OOP) is a type of programming added to php5 that makes building complex, modular and reusable web.
Presented by Ted Higgins, SQL Server DBA An Introduction to Object – Oriented Programming.
Classes CSCI 201L Jeffrey Miller, Ph.D. HTTP :// WWW - SCF. USC. EDU /~ CSCI 201 USC CSCI 201L.
Author: DoanNX Time: 45’.  OOP concepts  OOP in Java.
Topics Instance variables, set and get methods Encapsulation
An Introduction to Programming with C++ Fifth Edition Chapter 14 Classes and Objects.
COMPUTER SCIENCE & TECHNOLOGY DEGREE PROGRAMME FACULTY OF SCIENCE & TECHNOLOGY UNIVERSITY OF UVA WELLASSA ‏ Properties of Object Oriented Programming.
Seventh step for Learning C++ Programming CLASS Declaration Public & Private Constructor & Destructor This pointer Inheritance.
Computer Programming II Lecture 5. Introduction to Object Oriented Programming (OOP) - There are two common programming methods : procedural programming.
Object-oriented programming (OOP) is a programming paradigm using "objects" – data structures consisting of data fields and methods together with their.
Object-Oriented Design
Objects as a programming concept
One class is an extension of another.
OBJECT ORIENTED PROGRAMMING II LECTURE 7 GEORGE KOUTSOGIANNAKIS
Table of Contents Class Objects.
Computing with C# and the .NET Framework
INTRODUCTION TO OBJECT-ORIENTED PROGRAMMING (OOP) & CONCEPTS
Object Oriented Analysis and Design
CSC 205 Java Programming II
One class is an extension of another.
OBJECT ORIENTED PROGRAMMING II LECTURE 8 GEORGE KOUTSOGIANNAKIS
Object Oriented Programming
Features of OOP Abstraction Encapsulation Data Hiding Inheritance
CS2011 Introduction to Programming I Objects and Classes
CLASSES AND OBJECTS.
Object Oriented Programming
COP 3330 Object-oriented Programming in C++
Object Oriented Programming
OOP Aga private institute for computer science 5th grade
2.1 Introduction to Object-Oriented Programming
By Rajanikanth B Classes in Java By Rajanikanth B
Classes.
CSG2H3 Object Oriented Programming
Introduction to Computer Science and Object-Oriented Programming
Presentation transcript:

By Rajanikanth B www.btechsmartclass.com OOP Concepts By Rajanikanth B www.btechsmartclass.com

OOP stands for Object Oriented Programming Introduction OOP stands for Object Oriented Programming

Majorly there are FOUR concepts in OOPs Introduction Majorly there are FOUR concepts in OOPs

Introduction 1. Encapsulation 2. Abstraction 3. Polymorphism 4. Inheritance

BEFORE… start these concepts We must know the following What is an Object? What is a class?

ENCAPSULATION Encapsulation = Data + Code Process of combining data and code Encapsulation = Data + Code Here Data represents Variables in program Here Code represents functions in program

ENCAPSULATION Encapsulation = Data + Code This concept can be implemented using class Class = variables + functions Encapsulation = Data + Code Class is a collection of variables and functions under single unit

ENCAPSULATION Attributes Behavior BankAccount class BankAccount { String name ; int accountNumber; double balance ; String dateOpened; String accountType; String branch; String name ; int accountNumber; double balance ; String dateOpened; String accountType; String branch; Behavior void open( ){….} void close( ){….} void deposit( ){….} void withdraw( ){….} void open( ){….} void close( ){….} void deposit( ){….} void withdraw( ){….} }

Simply abstraction is hiding information which is not required Process of focusing on the essentials, ignoring the irrelevant and unimportant things Simply abstraction is hiding information which is not required

ABSTRACTION We use access modifiers to implement this concept We use keywords like public, private, protected, friend….

ABSTRACTION private All the members which are declared under private can be accessed by same class members only. No other class can not access the private members of any other class.

ABSTRACTION public All the members which are declared under public, can be accessed by any class members and from any where.

ABSTRACTION protected All the members which are declared under protected, can be accessed by same class members and its derived class members.

ABSTRACTION Modifier Class Package Subclass World public Yes Yes Yes protected Yes Yes Yes No private Yes No No No No modifier Yes Yes No No