I tried to look for a good definition but couldn't find anything.
Can somebody give me a short and exact definition of these two terms ??
I know that
class= a user defined data type which consists data and functions
???
object= ??
I know what objects are and what they do but can't come up with a definition.
Thanks,
Roni.
how would you define the terms 'classes' and 'objects' ?
Started by roniy, Aug 24 2009 04:37 PM
5 replies to this topic
#1
Posted 24 August 2009 - 04:37 PM
|
|
|
#2
Posted 24 August 2009 - 04:52 PM
An object is an instance of a class. A class doesn't "occupy memory", an object does. Your definition of a class is pretty good, actually.
#3
Posted 24 August 2009 - 05:12 PM
WingedPanther said:
An object is an instance of a class. A class doesn't "occupy memory", an object does. Your definition of a class is pretty good, actually.
I see, thank you :)
#4
Posted 25 August 2009 - 02:38 AM
The way that I always think of the difference between the two is:
Object - exists in memory like a real object exists in space.
Class - is the blueprint for how to make an object.
Object - exists in memory like a real object exists in space.
Class - is the blueprint for how to make an object.
#5
Posted 25 August 2009 - 09:11 AM
Er, I always though an object is just a generic term for a class like structure in a programming language. Then an instance is the way to describe an instance of the object in memory.
#6
Posted 25 August 2009 - 09:52 AM
[7] Classes and objects, C++ FAQ Lite
Also,
Also,
C99 said:
object
region of data storage in the execution environment, the contents of which can represent values
region of data storage in the execution environment, the contents of which can represent values


Sign In
Create Account


Back to top









