« 6TH POPE Home | Email msg. | Reply to msg. | Post new | Board info. Previous | Home | Next

Object Oriented Programming

By: Zimbler0 in 6TH POPE | Recommend this post (0)
Fri, 02 Oct 20 3:43 AM | 27 view(s)
Boardmark this board | 6th Edition Pope Board
Msg. 06818 of 60014
Jump:
Jump to board:
Jump to msg. #

(And I would love to have another person correcting
any misconceptions I might have on this subject.)

The core concept behind Object Oriented Programming is the 'Object'. And the
Object is a construct within the program (or computer) which has traits,
capabilities, parameters and variables associated with it. The 'Class'
would be the code that has and creates the object and contains the code
that make up the capabilities of the object.

Remember De's turtle racing program? Each of them turtles was an object
of the class Turtle. Each has abilities such as go left, go right, run
in a circle, draw or not draw. Color. Lots of cool things.

To try and understand this with a (poor) analagy in the real world.
We'll say we have a 'Class' called 'SportsCar'. This Class has the
design, parts lists, programs, and everything necessary to build one
up a nice, fast, sports car. One would 'invoke' the class and have it
build the sportscar and away we go.

An interesting thing is called 'inheritance'. We can take this basic
sportscar class, and use it as a template for another class. Being
begat from 'sportscar' we can add new features. As in having 'Q' design
up and add to the basic design such features as machine guns, rocket launchers,
caltrops, oil slick nozzles, and a license plate changer. And we will
call this new class 'JamesBondSportsCar'.

And when we instantiate a 'JamesBondSportsCar' we can drive it off and
kick some serious tushe with it.

Zim.




Avatar

Mad Poet Strikes Again.




» You can also:
« 6TH POPE Home | Email msg. | Reply to msg. | Post new | Board info. Previous | Home | Next