On 12/8/06, Marc Santhoff <[EMAIL PROTECTED]> wrote:
One working solution is to use a global var. This is bad but acceptable
for a singleton imo. If would be nice if the variable could be hidden.


This is kinda what I have been using all along, except, I have a
function, that creates the instance when used for the first time.  I
call it the Lazy mans Singleton.  It works perfectly, if the developer
knows about the global function!  Otherwise, they might still try and
create a instance of the class, which is what I am trying to prevent.


--
Graeme Geldenhuys

There's no place like S34° 03.168'  E018° 49.342'
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to