Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #4250

Re: Composition instead of inheritance

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!feeder.news-service.com!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <prvs=0922bbad7=jeanmichel@sequans.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.011
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'recipe': 0.07; 'python': 0.07; 'url:activestate': 0.09; '~ethan~': 0.09; 'url:code': 0.11; 'wrote:': 0.14; 'furman': 0.16; 'received:192.168.200': 0.16; 'great.': 0.16; 'cc:2**0': 0.20; 'header:In-Reply-To:1': 0.22; 'cc:addr:python-list': 0.22; 'posted': 0.22; 'instead': 0.26; 'cc:addr:python.org': 0.31; '(for': 0.33; 'received:192': 0.34; 'header:User-Agent:1': 0.35; 'received:192.168': 0.37; 'but': 0.38; 'completely': 0.38; 'comments': 0.39; 'would': 0.40; 'fear': 0.73; 'composition': 0.84; 'inheritance,': 0.91
X-IronPort-AV E=Sophos;i="4.64,282,1301868000"; d="scan'208";a="1423857"
X-Virus-Scanned amavisd-new at zimbra.sequans.com
Date Thu, 28 Apr 2011 20:59:24 +0200
From Jean-Michel Pichavant <jeanmichel@sequans.com>
User-Agent Mozilla-Thunderbird 2.0.0.24 (X11/20100328)
MIME-Version 1.0
To Ethan Furman <ethan@stoneleaf.us>
Subject Re: Composition instead of inheritance
References <4DB9A096.3020200@stoneleaf.us>
In-Reply-To <4DB9A096.3020200@stoneleaf.us>
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
Cc Python <python-list@python.org>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.953.1304017167.9059.python-list@python.org> (permalink)
Lines 13
NNTP-Posting-Host 82.94.164.166
X-Trace 1304017168 news.xs4all.nl 81476 [::ffff:82.94.164.166]:59579
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:4250

Show key headers only | View raw


Ethan Furman wrote:
> For anybody interested in composition instead of multiple inheritance, 
> I have posted this recipe on ActiveState (for python 2.6/7, not 3.x):
>
> http://code.activestate.com/recipes/577658-composition-of-classes-instead-of-multiple-inherit/ 
>
>
> Comments welcome!
>
> ~Ethan~
Sounds great. But I fear that would completely fool any linter.

JM

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Composition instead of inheritance Jean-Michel Pichavant <jeanmichel@sequans.com> - 2011-04-28 20:59 +0200

csiph-web