Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread Ralph Schindler
> Ralph, > Looks interesting, "Namespace & PseudoNamespace loading capabilities" > sounds similar to the class loader I'm using. I think having multiple > loaders available within ZF is a great idea, but I don't see much need > for Zend_Loader_Autoloader, as SPL already has good autoloader stack

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread Jack Sleight
Matthew, Yes absolutely. The only changes necessary are the four very simple replacements the script makes. As far as I know (although I've not tested every component) this is all that's required. Ralph, Looks interesting, "Namespace & PseudoNamespace loading capabilities" sounds similar to the cl

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread Ralph Schindler
I know of this problem too, I actually started working on a proposal for an autoloader that would "play nice" with other autoloaders. http://framework.zend.com/wiki/display/ZFPROP/Zend_Loader_Autoloader+-+Ralph +Schindler In short, it would allow you to register a namepsace "prefix" that would on

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread till
Hey Jack, On Tue, Dec 2, 2008 at 5:16 PM, Jack Sleight <[EMAIL PROTECTED]> wrote: > Hi Everyone, > Just wanted to post a quick update to my previous script, which is now > compatible with 1.7.1 and Zend_Loader_PluginLoader, the code is here: > > http://pastebin.com/f19b4676 > > Place it in a direc

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread Matthew Weier O'Phinney
-- Jack Sleight <[EMAIL PROTECTED]> wrote (on Tuesday, 02 December 2008, 05:32 PM +): > The second problem is that at present, it is not possible to use your > own class loader with ZF (which is something I want to do). This is > because there are many calls to Zend_Loader::loadClass() hard cod

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-03 Thread Jack Sleight
Hi Till, Yeah, I should probably write some more details about the script, will do a blog post when I get a chance. Basically the script solves two problems. Firstly, as you may have seen, there's been a lot of discussion about removing all the require_once statements from ZF, in order to improve

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-12-02 Thread Jack Sleight
Hi Everyone, Just wanted to post a quick update to my previous script, which is now compatible with 1.7.1 and Zend_Loader_PluginLoader, the code is here: http://pastebin.com/f19b4676 Place it in a directory, create a subdirectory called "source" and put a copy of ZF in it. Create a new folder cal

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-12 Thread Michał Zieliński
Shame, but I understand. Thanks for clarification. Matthew Weier O'Phinney-3 wrote: > > -- Michał Zieliński <[EMAIL PROTECTED]> wrote > (on Monday, 11 August 2008, 10:27 PM -0700): >> Although in >> http://www.nabble.com/Zend_Form-and-generating-fields-td18826312.html#a18830980 >> one thread

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-12 Thread Matthew Weier O'Phinney
-- Michał Zieliński <[EMAIL PROTECTED]> wrote (on Monday, 11 August 2008, 10:27 PM -0700): > Although in > http://www.nabble.com/Zend_Form-and-generating-fields-td18826312.html#a18830980 > one thread Matthew said that performance audit is considered for 1.7 > release I hope the changes which spee

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-12 Thread Jack Sleight
Hi Micha?, You should be able to see the code formatted correctly if you open up the .php file attachment, I'm not sure why the email clients don't display it correctly, but the file is there in full with all formatting. Micha? Zieli?ski wrote: Jack, could you please paste the formatted code

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-11 Thread Michał Zieliński
Jack, could you please paste the formatted code on the http://paste2.org/ or elsewhere. It would be easier to look at. Summarizing... To get better performance (at the time) of ZF you need to remove all require_once from lib classes and write your own autoloader based on SPL? Right? (of course u

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-11 Thread Jack Sleight
Here is the script I've written to remove the require_once and loadClass calls from ZF. This does not fix the HelperBroker issue, that change will need applying manually. -- Jack current(), PATHINFO_EXTENSION) === 'php'); } } $directory = 'zend-framework/library/'; $iterator = new Recursiv

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-11 Thread Jack Sleight
Matthew Weier O'Phinney wrote: We've already identified the HelperBroker as being in need of refactoring to use Zend_Loader_PluginLoader. However, that class, too, relies partially on the include_path when the paths provided are not absolute paths. Have you had a chance to test any components tha

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-10 Thread Matthew Weier O'Phinney
-- Jack Sleight <[EMAIL PROTECTED]> wrote (on Sunday, 10 August 2008, 09:07 PM +0100): > However, there is one more problem. As I mentioned before, I didn't want > it to be a requirement to have the ZF library path in the include_path, > however at present Zend_Controller_Action_HelperBroker re

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-10 Thread Jack Sleight
Good to hear this is moving forward. I've been doing some tests of my own over the last 24 hours on the 1.5.3 release. I've run into a few issues, but nothing that cant be resolved. For the benefit of anyone who's interested, this is what I've been doing: My aim was to allow the use of any cla

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-10 Thread Matthew Weier O'Phinney
-- Jack Sleight <[EMAIL PROTECTED]> wrote (on Sunday, 10 August 2008, 12:30 AM +0100): > Bill Karwin wrote: >> ZF needs to remove all class-loading logic and instead rely on the SPL >> autoloader. > I'd really like to see this. There's also the discussion in the wiki > (http://framework.zend.co

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-09 Thread Jack Sleight
Bill Karwin wrote: ZF needs to remove all class-loading logic and instead rely on the SPL autoloader. I'd really like to see this. There's also the discussion in the wiki (http://framework.zend.com/wiki/display/ZFDEV/Performance+-+Requiring+the+Autoloader) about removing all require_once statem

Re: [fw-general] Overriding Zend_Loader::loadClass()

2008-08-09 Thread Bill Karwin
Jack Sleight wrote: > > Are there any plans to make it possible to use your own class loader, > perhaps a setting in Zend_Loader that'll allow you to specify an > alternative loadClass method? > My opinion (for what it's worth, since I'm no longer a contributor to ZF) that I've stated before

[fw-general] Overriding Zend_Loader::loadClass()

2008-08-09 Thread Jack Sleight
Hi, I'm now using my own "loader" class for including class files in my application (instead of Zend_Loader), and would ideally like all classes to be loaded through it. It successfully works with any require/include(_once) calls and "class ... extends/implements ..." statements in ZF (due to