Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:27562 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 78719 invoked by uid 1010); 21 Jan 2007 16:18:40 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 78688 invoked from network); 21 Jan 2007 16:18:40 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Jan 2007 16:18:40 -0000 Authentication-Results: pb1.pair.com header.from=schultz@widescreen.ch; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=schultz@widescreen.ch; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain widescreen.ch from 62.2.95.247 cause and error) X-PHP-List-Original-Sender: schultz@widescreen.ch X-Host-Fingerprint: 62.2.95.247 mxout.hispeed.ch Linux 2.4/2.6 Received: from [62.2.95.247] ([62.2.95.247:44678] helo=smtp.hispeed.ch) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 89/0A-33373-88193B54 for ; Sun, 21 Jan 2007 11:15:06 -0500 Received: from [127.0.0.1] (84-72-85-223.dclient.hispeed.ch [84.72.85.223]) (authenticated bits=0) by smtp.hispeed.ch (8.12.11.20060308/8.12.11/taifun-1.0) with ESMTP id l0LGEwjP014044 for ; Sun, 21 Jan 2007 17:14:59 +0100 Message-ID: <45B39184.7010904@widescreen.ch> Date: Sun, 21 Jan 2007 17:15:00 +0100 User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: internals@lists.php.net References: <45B0E1EE.2030102@widescreen.ch> <200701192122.38663.pstradomski@gmail.com> In-Reply-To: <200701192122.38663.pstradomski@gmail.com> Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 0704-0, 18.01.2007), Outbound message X-Antivirus-Status: Clean X-Virus-Scanned: ClamAV version 0.88.7, clamav-milter version 0.88.7 on smtp-06.tornado.cablecom.ch X-Virus-Status: Clean X-DCC-spamcheck-02.tornado.cablecom.ch-Metrics: smtp-06.tornado.cablecom.ch 1378; Body=1 Fuz1=1 Fuz2=1 Subject: Re: [PHP-DEV] PHP Object-Caching and Reference Counting From: schultz@widescreen.ch (Lars Schultz) >Perhaps you could use your own reference counting? >Keep your "real" objects in private array and instead of returning them return >a simple object which would forward all methods and properties by >__get/__set/__call. The constructor would increase your internal refcount by >one, destructor would decrease it. > > I use those objects quite often as they are used to access the database to manipulate or search for related data. It wouldn't perform well and is actually not at all practicable because there are so many classes for which I'd would have to copy the interface.