Re: [PEPr] Comment on Database::table_browser
| From: | Christian Weiske | Date: | Sat, 30 Aug 2008 08:42:29 +0000 |
| Subject: | Re: [PEPr] Comment on Database::table_browser | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-50683@lists.php.net to get a copy of this message | ||
Hello Isaac,
> confusion in user code. A static method (factory, singleton,...)
> would be more appropriate. -Agreed, excellent suggestion, I will
> implement this in this version.
Factory please, no singleton.
> 4) No Iterator / IteratorAggregate implementation
> -My objective was to use a browser model, where one creates a browser
> object to see successive snapshots of data. I want to give the user
> the ability to get these snapshots and not get in the way of what
> they do with the results. The object is the browser, the results are
> transient.
Implementing an Iterator interface means that you can
foreach ($tablebrowser as $row) {
...
}
> 8) No ArrayAccess implementation
> -I am not sure I understand this...is this similar to your 4th point?
Same as 4, but with []
> 9) Way far from PEAR's coding standards, but this is very minor at
> this stage of proposal given the items above.
> -I will be adding more documentation, what would you say is the most
> glaring difference(s)?
Try to run php codesniffer on your code.
--
Regards/Mit freundlichen Grüßen
Christian Weiske
-= Geeking around in the name of science since 1982 =-
Attachment: [application/pgp-signature] signature.asc
Attachment: [application/pgp-signature] signature.asc