Re: Software Architecture/Design

[email protected]
Newsgroups gmane.games.devel.sweng
Message-ID <1031554471.1626231276187484442.JavaMail.root@spooler1-g27.priv.proxad.net>
----- [email protected] a écrit :
> > Data and properties are different things, and I've
> > yet to see a case where "the data knows something".
> >
> > -- Emmanuel Deloget
> 
> The usual Singleton pattern variations for example "know" that they
> are the only instance of their class.
> 
> (You could argue that this knowledge is not part of the data itself
> but the code associated with it, but since this knowledge is used by users
> of the class, in practical terms I would have to disagree)

Just to be clearer : a singleton is not a data, it's a mix of data, behaviors and properties. When I say "data", I really mean "data" : textures, vb, or even a full database (not a database system ; just the database itself). When you associate a behavior to a data, you don't handle a data anymore - you handle an entirely different entity (which we often refer to as an object ; the difference between an object and some data is so huge that you can compare it to the difference between a cat and a crate). Objects (such as the singleton) knows things - and most of time they know many of them, including how to behave in such and such situation - but data don't know anything. It even doesn't know whether it exists or not (you have to add a behavior to know that, in which case you get an object). 

I know I can be a nitpicker sometimes. But I think using clear dichotomies can ease the understanding of the current discussion and its derived talks. 

> -- 
> Javier Arevalo
> http://www.iguanademos.com/Jare

Best regards,

-- Emmanuel Deloget
_______________________________________________
Sweng-Gamedev mailing list
[email protected]
http://lists.midnightryder.com/listinfo.cgi/sweng-gamedev-midnightryder.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.