🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #14735

Re: hiding methods

#14735
From: Steve Horsley
Date: Thu, 05 Aug 1999 00:00
12 lines
1093 bytes
As a further thought, perhaps your class should not extend Panel
at all, since you don't intend to USE it as a panel. Perhaps it
should extend Component since that's what it really is. 

It could privately contain a Panel to draw on.
You would probably then have to override all the Component methods
and redirect them to your contained Panel, so that all the paint()
methods and such like actually happen on the contained panel.

This is harder to do, but probably the most 'correct' OOP way.

Steve.
Technical Details
Message-ID: <37A9AF5A.563C5F77@cwcom.co.uk>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <37A94A3C.7124DC62@c-content.nl> <37A9750D.B0F53C0C@cwcom.co.uk>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,c7695f50bddab9ba
X-Google-Attributes: gidf74b3,public
From: Steve Horsley <steve.horsley@cwcom.co.uk>
Subject: Re: hiding methods
Date: 1999/08/05
Message-ID: <37A9AF5A.563C5F77@cwcom.co.uk>
X-Deja-AN: 509214843
Content-Transfer-Encoding: 7bit
References: <37A94A3C.7124DC62@c-content.nl> <37A9750D.B0F53C0C@cwcom.co.uk>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Cable & Wireless Communications
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.language