Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-25 Thread Jochem Maas
Stut wrote: Jochem Maas wrote: Simas Toleikis wrote: thing :-/ Though i wonder if there are any other hacks using some sort of classkit/other class manipulation functions? probably runkit (or is it classkit - can't remember which of those is more actively developed) might give a way out -

Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-25 Thread Stut
Jochem Maas wrote: Simas Toleikis wrote: thing :-/ Though i wonder if there are any other hacks using some sort of classkit/other class manipulation functions? probably runkit (or is it classkit - can't remember which of those is more actively developed) might give a way out - but I would reco

Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-24 Thread Richard Lynch
On Mon, April 24, 2006 2:18 pm, Simas Toleikis wrote: >> php6 will include static late binding > > Great. Love the other new features, especially namespaces. > >> - until then you have 2 choices, >> create a hack (see below) or stick redundant code into each class >> you >> want to be a singleton.

Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-24 Thread Jochem Maas
Simas Toleikis wrote: php6 will include static late binding Great. Love the other new features, especially namespaces. not sure namespaces will make it ... I believe the decision on that is still out. - until then you have 2 choices, create a hack (see below) or stick redundant code int

Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-24 Thread Simas Toleikis
> php6 will include static late binding Great. Love the other new features, especially namespaces. > - until then you have 2 choices, > create a hack (see below) or stick redundant code into each class you > want to be a singleton. The hack doesn't work (See below). Guess we are left with copy-p

Re: [PHP] Reusable Singleton pattern using PHP5

2006-04-24 Thread Jochem Maas
[top posting to just to spite the anti-top-posting crowd :-P] php6 will include static late binding - until then you have 2 choices, create a hack (see below) or stick redundant code into each class you want to be a singleton. (welcome to the club that thinks this should have been possible right