Updated package proposal: Services_Exchange (was Payment_Exchange)

From: Date: Thu, 28 Aug 2003 11:18:47 +0000
Subject: Updated package proposal: Services_Exchange (was Payment_Exchange)
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-20735@lists.php.net to get a copy of this message
Taking the recommendations of Alan and Tomas, I have renamed the package to Services_Exchange and created drivers for all of the feeds. I couldn't use the factory pattern as Alan suggested, but it appears to be the same idea: you specify which source you want, it includes the appropriate driver, and then instantiates the driver's class. The driver's class extends a Common function, which will contain methods to retrieve each different type of file. XML is the only source type right now, so Services_Exchange_Common::retrieveXML() handles the caching/downloading and returns an XML_Tree object. Then the driver does the specific parsing necessary to return the correct array. In the case of a database, Services_Exchange_Common::retrieveDB() would connect to the database and query for the necessary information. It would return an array to the driver, which would clean it up if needed. I'm still looking for comments and three more +1s. -- Marshall Roch

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