[Phpmyadmin-devel] Refactoring: Displaying query results
alex.ukf at gmail.com
Fri Jun 29 00:14:58 CEST 2012
On Thu, Jun 28, 2012 at 11:38 PM, Dieter Adriaenssens
<dieter.adriaenssens at gmail.com> wrote:
> Just an idea, while reading your description of how to use the
> transformation classes : why don't you provide a factory pattern to
> instantiate/create the classes. Everything like checking if the include file
> exists, including it and preparing/instantiating can be done in the factory.
That sounds like a good idea.
> Also consider creating an interface for every type of class (auth,
> export/import, transformation, ...) and implement it in every derived class
> (f.e. ExportSql, ExportXml could implement a ExportInterface)
Currently, this is implemented with abstract classes (f.e. ExportSql and
ExportXml extend ExportPlugin and so on), and those provide a similar
functionality to the interface. I decided to use abstract classes, because
I wanted to be able to declare some common variables and getters and
setters for them.
More information about the Developers