Zend Framework for Recess

7 views
Skip to first unread message

Joshua Paine

unread,
Apr 24, 2009, 10:42:20 AM4/24/09
to Recess Framework
I've written a script to convert the Zend Framework files to use Recess'
autoloading features, which means you use them just like any other class
or lib in Recess, and any classes you use get cached in Recess'
production mode cache so you avoid the one file per class performance
hit.

The 7MB zip file at <http://papercrown.org/files/ZF-Recess.zip> includes
the current Zend Framework 1.7 in folder 'Zend', the derived
Recess-compatible versions in folder 'ZF', and the script that does that
automatic conversion.

You must copy the ZF folder into your recess apps dir or plugins dir,
keeping the name ZF. Then you can do things like this:

Library::import('ZF.Zend_Mail');
$mail = new Zend_Mail();

There are probably some things that don't work, but the ZF codebase is
extremely consistent and rigorous in their practices, so the conversion
was pretty straightforward, and I have some confidence in it. Some
things, like the Zend_Loader, don't make any sense to use but are
included for completeness (actually, because it's easier to just include
everything than go through and see if there's anything that doesn't
belong).

If you want to regenerate your own copy, just do something like this in
your shell:

#> cd ZF-Recess
#> rm -Rf ZF
#> php recess-zf.php

And about 0.6 seconds later, it's done.

Let me know if you use it and find any issues. I think using Recess'
class loader (instead of just hacking in Zend's, too) is a winner, so I
want to make sure there's a reliable conversion process.

--
Joshua Paine
LetterBlock: Web applications built with joy
http://letterblock.com/
301-576-1920

Reply all
Reply to author
Forward
0 new messages