alt
Advertisement
Sponsored links
Online Training
Career Series
Exforsys
Exforsys arrow Tutorials arrow OOPS arrow Object Oriented Programming Introduction
Site Search


Object Oriented Programming Introduction

Object Oriented Programming Introduction

Object Oriented Programming, also known as OOP, is a computer science term which is used to describe a computer application that is composed of multiple objects which are connected to each other. Traditionally, most computer programming languages were simply a group of functions or instructions.



With OOP, every object can handle data, get messages, and transfer messages to other objects. The objects will all act as independent units in their own right, and they will be responsible for carrying out a certain process.

Because the objects are not dependent on each other, OOP is seen as being more flexible than older methods of programming. It has become quite popular, and it is now used in a number of advanced software engineering projects. Many programmers feel that object oriented programming is easier for beginners to learn than previous programming methods. Because it is easier to learn, it can also be analyzed and maintained without a large amount of difficulty. However, there are some people that feel that OOP is more complicated than older programming methods. To understand object oriented programming, there are a few concepts you will need to become familiar with.

The first concept that you will need to learn is called a "class." A class creates the attributes of a thing, and it will also define the processes that the thing can carry out. For example, a class called "cats" will have the attributes which are commonly found with cats, such as the ability to purr. A class will bring about modularity within the objected oriented computer application. Someone who is not a programmer should be able to find a class. The reason for this is because the attributes of the class should be something that will make sense to them. It is also important for the code of a class to be self contained to a certain degree. When code is written with relevant names, it will be easier to understand. Making sure the code is self-contained will allow one part of the application to be updated without needing to change the other parts.

It is this modularity that makes OOP an effective programming method. It will also help the application solve the problems that it was designed for. The next concept that you will want to become familiar with is an "object." An object can be defined as a specific instance of a class. As an example, while the class Cats will provide all the attributes that are found in all cats, the "object" named Betsy is a specific cat. While it shares the same attributes which are found in all cats, it has fur with a unique color. In object oriented programming, a programmer would say that the object Betsy is a run-time instance of the class Cats.

A class may also be devided into sub-groups. Certain variations of a class may not be a specific object. The class Cats may have a sub-group which consists of multiple cat breeds. For example, if Betsy were a Persian cat, it would be an instance of the Persian cat sub-group. Every object within an OOP language will share some attributes with the parent class, but it will also have unique attributes as well. The next concept that you will want to become familiar with is "method." A method may also be called a "message" and can be defined as the abilities of an object. Because Betsy is a cat, Betsy can purr. Because of this, "purr" is a method that Betsy has.



Betsy may have a number of other methods. When a method is used within an object oriented programming language, it will only affect a single object. This is true even if the method is designed for the entire class. While all cats can purr, you will only need one cat to do it. Methods can further be broken down into commands, callbacks, or queries. A query will tell you about the state of the object, and a command will cause that object to carry out a task. A callback is a method that is composed of a part within an object. The part will notify its parent that an event has taken place, and the object may need to react to the event.


Trackback(0)
Comments (22)add comment

bogdan said:

  I am trying to learn c and until I found your website I was very confuse...good work....really good work!
Thank you!
September 13, 2006

sanjay lakhanpal said:

  It's really a very good article.Thanx
May 17, 2007

rvijay said:

  super step by step teaching
May 22, 2007

sidhu said:

  the explination is gud
May 28, 2007

Richagupta said:

  Hi, Ur site is awesome for an abosulte beginner and programmer too. You did great.
I was very releived after i found ur site.

pls keep doing this and Add more tutorials.

Thanks a ton
May 30, 2007

sheelu said:

  It is the best site for learners. I am enjoying it.
June 08, 2007

Guru MCA said:

  This type of Articles are better to understand, is Explained from basic,it will UnderStands Easily.

Thanks

GuruPrasad.Y
Bangalore
June 12, 2007

sandeep kumar bs said:

  honestly speaking...before i read ur article i read many other sites where there was an expalination given....but no where as good as this...ur article tells how to understand things in a systematic way....i appreciate it gr8ly!!!
thanks alottt!!

cheers
sandeep
July 04, 2007

dhantu said:

  One of the best, 've ever read. Provide us a full application/project for practice. This would make us understand directory structure, linking of different tools, architecture of the project, etc.,
Finally, something on UML diagrams would be more beneficial.

Wonderful tutorial

July 26, 2007

Ashish Kapoor said:

  I am good I practicle but when it's come to theory or reasoning I am NULL.

Thanks to you to make me understand the concepts.
August 02, 2007

Kapil Patel said:

  this is really good for me to understand
August 16, 2007

abhish said:

  thanks it is very helpful for me
keeep going
god blesss u all
August 20, 2007

Arvind jain said:

  I will say, its a great article i have ever read
August 22, 2007

Ruchir H Andharia said:

  It is Interesting to read your Article but give more Example about Class and Object with Attributes so Understand more easily
August 27, 2007

Minakshee said:

  My q is how to call the movie clip randomly???
i have 10 movie clip and i want to call them prequently?????
pls solve my problem...

thnaks..
Minakshee
September 08, 2007

johnson raja said:

  Thank u for providing me an wonderful article regarding oops concept .
Now iam clear in all my doubts......................


Thanks
Johnson raja
October 25, 2007

Gopz said:

  Its really good place to learn some basics and actually i dont know what is MVS and from ur site i leart lot from that.really good site and best of all

great
gopz
October 30, 2007

Sijugeo said:

  Thanks for the wonderful article!!!
November 01, 2007

sanjiv sudhakar said:

  It's very good article
November 23, 2007

Suresh from Bangalore said:

  It is very very good. Because this site is explaining with details from the basics.
December 10, 2007

Sushma Veeram said:

  WOW Simply Superb, I am a Computer Consultant since 6 Years in UK. I am really pleased with this tutorials. Please do it the same to encourage some more Programmers. Great help for many people.
Cheers
December 22, 2007

antojo said:

  very brilliant explanation for programing
May 06, 2008

Write comment

busy
 
< Prev   Next >
Exforsys Offers
© 2008 Exforsys.com
Joomla! is Free Software released under the GNU/GPL License.
Page copy protected against web site content infringement by Copyscape