One class, one file?

From: Date: Sat, 07 May 2005 08:35:14 +0000
Subject: One class, one file?
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-37528@lists.php.net to get a copy of this message
Hello all, I was wondering if every class has to be in one file? My Net_Wifi package has one class which contains the functionality, and two ones which are "object wrappers" to access the data returned from the main class, e.g. class Net_Wifi { function scan() { $obj = new Net_Wifi_Data; $obj->essid = "asd"; $obj->rate = "11"; return $obj; } } class Net_Wifi_Data { var $essid = null; var $rate = null; } So Net_Wifi_Data is just a container class for simple data. Would it be ok to not pack it into an own file but append it to Net/Wifi.php? Regards/MfG, Christian Weiske -- XMMS is playing now: Sarah Connor - When i dream

Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc
« previous php.pear.dev (#37528) next »