2.0 OOP concepts - Computer science PDF

Title 2.0 OOP concepts - Computer science
Course Computer Systems
Institution University of the People
Pages 2
File Size 95.9 KB
File Type PDF
Total Downloads 61
Total Views 128

Summary

Computer science...


Description

2.0 OBJECT ORIENTED PROGRAMMING CONCEPTS OOPs concept: 1. Class 2. Object 3. Inheritance 4. Polymorphism 5. Encapsulation 6. Abstraction 7. Message priority. Class: • • •

A class is defined as a collection of objects with same type of data and function. Class is a user defined type. Once a class is defined we can create a number of objects belonging to that class.

Objects: • • • • •

Objects is defined as the basic runtime entities that contain data and its method. Objects may be a person, place or any item that the program has to handle. The objects may be either physical or logical. When a program is executed the objects interact by sending message to one another. Objects are the fundamental units of oops.

Inheritance: • • • •

It is a process of deriving new classes from existing classes. The inheritance concept gives data reusability. The derived class contains all attributes and function of existing class plus its own attributes and functions. Existing class is called as parent class or super class or base class and the derived class is called as child classes or sub class or derived class.

Polymorphism: •

Polymorphism means the ability to take more than one forms.

• •

An operation may exhibit the different instances. The behavior depends on the type of data used in the operation.

Data Abstraction (Data Hiding): Abstraction refers to the act of representing essential features without including the background details. Data Encapsulation (Data Binding): • • •

It is the process of combing data and function into a single unit called class. By this concept one cannot access the data directly. Data is accessible only through the functions present inside the class

Message Passing: It is a process of sending request to execute a function for an object Message passing involves specifying the name of the object name of the method and the information to be sent. Dynamic Binding: Dynamic binding means that the code associated with a given procedure call is not Known until the time of the call at run time....


Similar Free PDFs