Hi every1 This is a theorical question about the best way to use classes.
I have a class named anything, and also theres a table named ahything .. The class attributes are the same fields of the table like this Class anything { var $something1; var $something2; var $something3; } And the table 'anything' has 3 fields they are something1 , something2, something3, my question: I have a method in the class that retrieves the values for the 3 attributes from the table, there are many scripts that use this method to get the data, but not all the scripts uses the 3 attributes, for example a script calls the method just because only needs the attribute something1. should i write one method to retrieve each attribute ? Or is just fine that one method gets all data, and the scripts only uses what it needs ?? Of course, the real class has more than 3 attributes it has 10 attributes Thanks Any help would be very useful. Daniel. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php