Re: AW: [PEAR-DEV] [RfC] XML_Serializer

From: Date: Mon, 28 Jul 2003 23:22:55 +0000
Subject: Re: AW: [PEAR-DEV] [RfC] XML_Serializer
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-18858@lists.php.net to get a copy of this message
Stephan Schmidt wrote:
Hi,
Love it already :-) You have my +1 IF you remove that ugly $GLOBALS[] usage. Just add some class vars for the options and set them in the constructor or via an extra "_setOptions()" method (called by the constructor). Thus you can also get rid of "_adjustOptions()", since you can simply leave the default class-vars values.
I was thinking about this, but then there's no way to call the methods statically. this is what the singleton pattern is for.?
the whole class did look a little odd, using static methods everywhere, using the class var to store the output and options would seem a little more logical.. Is there some big reason for this? Regards Alan
BTW... also having a matching UNserializer would be really cool...
That's not easy, as there's no type information stored in the XML documents. You may want to take a look at patConfiguration, which allows you to "unserialize" an XML document. Download it at http://www.php-tools.de Stephan


« previous php.pear.dev (#18858) next »