[zeta-dev] [patch] ezcBaseOptions should be traverseable
Related issue : https://issues.apache.org/jira/browse/ZETACOMP-39 Hi there, you will find attached a patch for two alternatives to fix ZETACOMP-39. Alternative 1 (alternative1.diff): simply add a new method that return the list of available properties so a user can fetch them and do anything he wants with it. Alternatice 2 (alternative2.diff): ezcBase implements Iterator so doing a simple foreach makes it possible to loop through properties Any feedback welcome. :) -- Jérôme Renard http://39web.fr | http://jrenard.info | http://twitter.com/jeromerenard alternative2.diff.gz Description: GNU Zip compressed data alternative1.diff.gz Description: GNU Zip compressed data
Re: [zeta-dev] [patch] ezcBaseOptions should be traverseable
Jerome Renard wrote: Related issue : https://issues.apache.org/jira/browse/ZETACOMP-39 Hi there, you will find attached a patch for two alternatives to fix ZETACOMP-39. Alternative 1 (alternative1.diff): simply add a new method that return the list of available properties so a user can fetch them and do anything he wants with it. Alternative 2 (alternative2.diff): ezcBase implements Iterator so doing a simple foreach makes it possible to loop through properties Any feedback welcome. :) +1 iterator -- Jérôme Renard http://39web.fr | http://jrenard.info | http://twitter.com/jeromerenard
Re: [zeta-dev] [patch] ezcBaseOptions should be traverseable
All, On Wed, Feb 23, 2011 at 6:51 PM, Gaetano Giunta giunta.gaet...@gmail.comwrote: Jerome Renard wrote: Related issue : https://issues.apache.org/jira/browse/ZETACOMP-39 [...] Alternative 2 (alternative2.diff): ezcBase implements Iterator so doing a simple foreach makes it possible to loop through properties Here is a new patch implementing alternative 2 correclty (I completely forgot next(), current() ... functions). The patch (alternative3.diff) is now much cleaner. -- Jérôme Renard http://39web.fr | http://jrenard.info | http://twitter.com/jeromerenard alternative3.diff.gz Description: GNU Zip compressed data