Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:29158 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 13465 invoked by uid 1010); 3 May 2007 14:59:41 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 13450 invoked from network); 3 May 2007 14:59:41 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 3 May 2007 14:59:41 -0000 Authentication-Results: pb1.pair.com header.from=stas@zend.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=stas@zend.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain zend.com designates 212.25.124.162 as permitted sender) X-PHP-List-Original-Sender: stas@zend.com X-Host-Fingerprint: 212.25.124.162 mail.zend.com Linux 2.5 (sometimes 2.4) (4) Received: from [212.25.124.162] ([212.25.124.162:28208] helo=mail.zend.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 58/23-27633-BD8F9364 for ; Thu, 03 May 2007 10:59:41 -0400 Received: (qmail 16857 invoked from network); 3 May 2007 14:59:36 -0000 Received: from unknown (HELO ?127.0.0.1?) (10.1.3.179) by internal.zend.office with SMTP; 3 May 2007 14:59:36 -0000 Message-ID: <4639F8D6.8020802@zend.com> Date: Thu, 03 May 2007 17:59:34 +0300 Organization: Zend Technologies User-Agent: Thunderbird 2.0.0.0 (Windows/20070326) MIME-Version: 1.0 To: Etienne Kneuss CC: internals@lists.php.net References: <4631EE73.4050409@php.net> In-Reply-To: <4631EE73.4050409@php.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [patch] Dynamic access of static members/methods, and constants From: stas@zend.com (Stanislav Malyshev) > I've already proposed that 1-2 months ago, but now seems to be a good > time to discuss new things, so let's try again: > > I believe it would be nice to be able to dynamically reference static > members, constants, and methods. > > Currently, there is no way to do that and the only way would be to > create a static method and use call_user_func(array($classname, > 'getThat')); Could you describe a couple of use cases where you would use such things (i.e. in real world scripts/libraries)? -- Stanislav Malyshev, Zend Products Engineer stas@zend.com http://www.zend.com/