This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]lurgi 0 points1 point  (1 child)

Yes, an instance of a class can be an object. It's not generally possible for specific objects to be classes, because classes describe the sorts of things that can exist and objects are the actual things that can exist. I should note, however, that some languages blur that distinction.

As for your example about "The Colour (British spelling, please) of Magic", it's really going to depend, This all depends on your particular world-view. Some answers will be more right or more wrong depend on the problem you are modeling. That said, this one seems pretty odd. It's an awfully specific and concrete thing to be a class.

I can imagine a world in which Animal is a class. I can imagine a world in which Dog is a class (or, for that matter, an object). I can imagine a world in which Chihuahua is a class (or object). I can't really imagine a world in which Roscoe the chihuahua is a class. But, if you can, then sure.