Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:10470 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 69359 invoked by uid 1010); 15 Jun 2004 14:37:36 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 69276 invoked from network); 15 Jun 2004 14:37:35 -0000 Received: from unknown (HELO is.magroup.ru) (213.33.179.242) by pb1.pair.com with SMTP; 15 Jun 2004 14:37:35 -0000 Received: from localhost.localdomain ([192.168.3.226]) by is.magroup.ru with Microsoft SMTPSVC(5.0.2195.6713); Tue, 15 Jun 2004 18:38:16 +0400 Date: Tue, 15 Jun 2004 18:38:16 +0400 To: internals@lists.php.net Message-ID: <20040615183816.2bdb17a4.tony2001@phpclub.net> In-Reply-To: <20040615143256.44336.qmail@pb1.pair.com> References: <20040615175918.57e77cbb.tony2001@phpclub.net> <20040615143256.44336.qmail@pb1.pair.com> X-Mailer: Sylpheed version 0.9.11 (GTK+ 1.2.10; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 15 Jun 2004 14:38:16.0678 (UTC) FILETIME=[652F7060:01C452E6] Subject: Re: [PHP-DEV] Re: Weird behaviour of private attribute + overloaded method From: tony2001@phpclub.net (Antony Dovgal) On Tue, 15 Jun 2004 16:32:55 +0200 Johannes Schlueter wrote: > Hi, > > that's imho expected behaviour. To quote > http://www.php.net/zend-engine-2.php > | Protected member variables can be accessed in classes extending the > | class they are declared in, whereas private member variables can > | only be accessed by the class they belong to. > > And $id belongs to the base class and not to the extended. What else > should be the difference between private and protected? I just was baffled by the fact, that without setId() in the extended class it works fine. But now I got it, thanks. And sorry for the noise. --- WBR, Antony Dovgal aka tony2001 tony2001@phpclub.net || antony@dovgal.com