Skip to main content

OOP's( Object Oriented programming)

The object oriented approach views off problem in terms of objects involved rather than procedure for doing it. Object oriented program names is defined as a method of implementation in which programs organised are cooperative collections of objects, each of which is an instance of some class.

The following general concept of oops are:
1) Object
2) Class
3) Data abstraction
4) Data encapsulation
5) Polymorphism
6)  Dynamic binding
7) Message passing
8) Inheritance

1) Object: Object is an entity that can Store send and receive messages and an instance of a class. Each object contains both data and code to manipulate the data objects can interact without having to know details of each objects Data and code.
For eg: person, place and table etc.

2) Class: A class is a collection of objects that share common properties and relationships. For example you can think of a buses as objects. They have characteristics like steering wheel, motor, seats etc. And their behaviour is their mobility. However bus is not an object, it is a class.
Other example: we can say bird is a class but sparrow is an object.

3) Data Abstraction: Data abstraction refers to the act of representing essential features without including the background details or explanations for example you are driving a car.you only know the essential features to drive a car example gear handling, steering handling, use of clutch etc. But while driving you will not go into internal details of car like wiring, motor working etc.

4) Encapsulation: The wrapping of data and functions into single unit is known as  encapsulation. Encapsulation is a way to implement data abstraction.

5) Inheritance: Inheritance is the process by which objects of one class acquire properties of objects of another class.a class which derived from another class is called derived class, a class which derived another class is called base class.
Inheritance is classified into following types:
a) Single inheritance: A method in which class derived from only one base class is called single inheritance.

b) Multiple inheritance: A method in which a class derived from several base classes is called multiple inheritance.

c) Hierarchical inheritance: A mechanism in which several classes are derived from single base class is called hierarchical inheritance.

d) Multilevel inheritance: The mechanism of deriving a class from another derived class is known as multilevel inheritance.

5) Hybrid inheritance: Mechanism of deriving a class from several other derived classes.

6) Polymorphism: Polymorphism is made up of two words "poly+ morphism" where:
 poly means "many"
morphism means "forms"
polymorphism is a process of defining a number of objects of different classes into a group and call the member function to carry out the operation of the objects using different functions polymorphism means the ability to take more than one form.



7) Dynamic Binding: Dynamic binding means to link the procedure call to the cord to be executed in response to the call. Dynamic binding means that the cord associated with the given procedure call is not known until the time of the call at runtime. It is associated with polymorphism and inheritance.

Comments

  1. Strange "water hack" burns 2lbs overnight

    More than 160k women and men are using a simple and SECRET "liquids hack" to drop 2lbs each and every night in their sleep.

    It is scientific and works on everybody.

    Just follow these easy step:

    1) Take a drinking glass and fill it up with water half the way

    2) Now learn this crazy hack

    and become 2lbs skinnier as soon as tomorrow!

    ReplyDelete

Post a Comment

If you find something wrong about this post please let us know. No Abusive Messages please.

Popular posts from this blog

Hub, repeater, switch, router, gateway, bridge

HUB Hub is a controller that controls the traffic on the network.  The following important properties of hub are:  1) It amplify signals. 2) It propagates signals through the network. 3) It does not require filtering. 4) It does not require path determination for switching. 5) It is used as network concentration points. Hubs are basically two types: 1) Active hub 2) Passive hub Active hub: A ctive hub works as repeater which is a hardware device that regenerates the received bit pattern before sending them out . Passive hub : A passive hub is a simple hardware device which provide a simple physical connection between the attached devices. Advantages of hub: It cannot filter the traffic full stop feeling generally refers to a process or device that screens network traffic for certain characteristics such as source address and destination address and protocol. Disadvantages of hub: On a hub, more than one user may try to send data on the network at sam

Scheduling: preemptive scheduling

Preemptive Scheduling : In contrast to non preemptive scheduling, a scheduling decision can be made even while the job is executing whereas in non preemptive scheduling, a scheduling decision is made only after job completes its execution. Therefor preemptive scheduling may force a job in execution to release the processor, so that the execution of some other job can be undertaken, in order to improve throughput considerably. Types of preemptive scheduling: 1) Round Robin scheduling algorithm : the round Robin scheduling is designed for time sharing systems. The primary objective of round Robin scheduling are interactive use, good response time and sharing the resources equitable among processes. It is similar to FCFS, but preemption is added to switch between processes. The processes are alocated a small unit of time. Known as time Quantum or time slice is in rotation until the completion of processes. To implement round Robin scheduling, a FIFO(first in first out) queue

Scheduling: Non-Preemptive Scheduling

Scheduling : In multi-programmed computer, multiple processes competing for the CPU at the same time. This situation occurs whenever two or more processes are simultaneously in the ready state. If only one CPU is available. Then we need a system that decide which process run first and then next and this will be done by the scheduler. Scheduler : scheduler is an operating system module that she loves an axe top to be admitted into the system and then the next process to run. Scheduling is of two type: 1) Pre-emptive 2) Non pre-emptive Non Pre-emptive Scheduling : In batch non Pre-emptive scheduling implies that, once scheduled, selected job runs to completion. In other words, the running process not forced to relinquish ownership of the processor when a higher priority process becomes ready for execution. The scheduling techniques which use non preemptive scheduling are: 1) first come first serve (FCFS) scheduling 2) shortest job next (SJN) scheduling 3) dea