You are here: Re: real world singleton class example? « PHP Programming Language « IT news, forums, messages
Re: real world singleton class example?

Posted by Jerry Stuckle on 12/01/06 21:21

Michael Fesser wrote:
> .oO(d.adamkiewicz@i7.com.pl)
>
>
>>Anybody can show me real world singleton class example?
>>Something that works (is implemented) as part of working solution.
>>Does it make sense to create database handler class that way?
>
>
> In my scripts I use a global application object, which is implemented as
> a singleton. This application object uses a lot of child objects, for
> example the db handler, configuration (registry), authentication, error
> handling/logging, sitemap and all that stuff.
>
> Micha

I just don't like to use global objects. I'd rather just have the
singleton class and those which need access to it can get it.

That way I don't have to worry about defining it as a global, among
other things.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация