Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #53435
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <timothy.c.delaney@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.057 |
| X-Spam-Evidence | '*H*': 0.91; '*S*': 0.02; 'python.': 0.02; 'attribute': 0.07; 'referring': 0.07; 'attributes': 0.09; 'python': 0.11; 'attribute.': 0.16; 'defined,': 0.16; 'pythonic': 0.16; 'roy': 0.16; 'wrote:': 0.18; 'define': 0.26; 'nearly': 0.26; 'header:In-Reply-To:1': 0.27; 'point': 0.28; 'correct': 0.29; 'tim': 0.29; 'message-id:@mail.gmail.com': 0.30; 'class': 0.32; 'implemented': 0.33; 'to:name:python-list': 0.33; 'skip:_ 10': 0.34; "i'd": 0.34; 'received:google.com': 0.35; "he's": 0.36; 'view,': 0.36; 'subject:?': 0.36; 'behind': 0.37; 'to:addr:python- list': 0.38; 'fact': 0.38; 'does': 0.39; 'to:addr:python.org': 0.39; 'providing': 0.61; 'our': 0.64; 'direct': 0.67; 'ethan': 0.84; 'furman': 0.84; 'absolutely': 0.87; 'contrary': 0.95; 'subject:skip:E 10': 0.95; '2013': 0.98 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=JkPDT0dFuiGe2yNAIFla4uV+VlX+8NuQUcSLmLHJvtE=; b=KEe3LVHjLqh6PacrA867adrpOdCLgQM4u8/G1R8F/mq+FTL4Y8KinLTRPBpmWxq+1b 8VqfajiwVdB407OQ4dKKKW7Y/jP7OjaPT2LL9y4jZ7eKnSDts1vyYtYjSRIhZIK7C7cB yciJino5gBZbNdt0eiqjmXNh++6WzDAKIJuE+vye1bEUQr4X5zY30pgbZX9Iomo8qwpe MnAkSZtmGqFzwKtAaDK+Eh6/1oKV3eVM4/dQ/OyCvLZjYK1L3qXnZa+nKLptH2+sGuv9 mUasmIoyFBXT4pVNKeYCIx9btN7yOT9VCMeCohkMPJVq/iBtc2Uvjmt7BJFWA0WyAdxo wDrw== |
| MIME-Version | 1.0 |
| X-Received | by 10.182.84.132 with SMTP id z4mr14866968oby.49.1378072493590; Sun, 01 Sep 2013 14:54:53 -0700 (PDT) |
| In-Reply-To | <5223A495.5070103@stoneleaf.us> |
| References | <8255dfbd-a2a1-4ab7-b900-ee19faa459f2@googlegroups.com> <8c7c4854-70e1-46e7-a3ff-a3206c4c5c27@googlegroups.com> <5221567b$0$6599$c3e8da3$5496439d@news.astraweb.com> <ecd32f98-6ba8-4b1e-91d3-e0fd6a8034c3@googlegroups.com> <5221d7ab$0$6599$c3e8da3$5496439d@news.astraweb.com> <ea5a462e-b3da-44cf-8697-fa07d381d3c5@googlegroups.com> <5222f675$0$6599$c3e8da3$5496439d@news.astraweb.com> <mailman.441.1378023704.19984.python-list@python.org> <9c11126f-93e8-461c-b487-bafc6b146269@googlegroups.com> <mailman.455.1378062400.19984.python-list@python.org> <roy-F4F03B.15130601092013@news.panix.com> <5223A495.5070103@stoneleaf.us> |
| Date | Mon, 2 Sep 2013 07:54:53 +1000 |
| Subject | Re: Encapsulation unpythonic? |
| From | Tim Delaney <timothy.c.delaney@gmail.com> |
| To | Python-List <python-list@python.org> |
| Content-Type | multipart/alternative; boundary=089e0111c09a748d3404e55981a5 |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| 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.461.1378072496.19984.python-list@python.org> (permalink) |
| Lines | 61 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1378072496 news.xs4all.nl 15863 [2001:888:2000:d::a6]:41597 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:53435 |
Show key headers only | View raw
[Multipart message — attachments visible in raw view] - view raw
On 2 September 2013 06:33, Ethan Furman <ethan@stoneleaf.us> wrote: > > class PlainPython: > > value = None > > > In the Javaesque class we see the unPythonic way of using getters/setters; > in the ProtectedPython* class we see the pythonic way of providing > getters/setters**; in the PlainPython class we have the standard, > unprotected, direct access to the class attribute. > > No where in PlainPython is a getter/setter defined, nor does Python define > one for us behind our backs. > > If you have evidence to the contrary I'd like to see it. > I think Roy is referring to the fact that attribute access is implemented via __getattr__ / __getattribute__ / __setattr__ / __delattr__. From one point of view, he's absolutely correct - nearly all attributes are accessed via getters/setters in Python. Tim Delaney
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Encapsulation unpythonic? fsaldan1@gmail.com - 2013-08-17 05:26 -0700
Re: Encapsulation unpythonic? Skip Montanaro <skip@pobox.com> - 2013-08-17 07:54 -0500
Re: Encapsulation unpythonic? David <bouncingcats@gmail.com> - 2013-08-17 23:05 +1000
Re: Encapsulation unpythonic? Chris Angelico <rosuav@gmail.com> - 2013-08-17 16:50 +0100
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-17 16:17 +0000
Re: Encapsulation unpythonic? Joshua Landau <joshua@landau.ws> - 2013-08-18 18:15 +0100
Re: Encapsulation unpythonic? Steven D'Aprano <steve@pearwood.info> - 2013-08-19 07:05 +0000
Re: Encapsulation unpythonic? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-08-19 18:57 -0400
Re: Encapsulation unpythonic? random832@fastmail.us - 2013-08-21 12:52 -0400
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-22 02:06 +0000
Re: Encapsulation unpythonic? Ian Kelly <ian.g.kelly@gmail.com> - 2013-08-21 16:02 -0600
Re: Encapsulation unpythonic? Gary Herron <gary.herron@islandtraining.com> - 2013-08-17 13:16 -0700
Re: Encapsulation unpythonic? Terry Reedy <tjreedy@udel.edu> - 2013-08-17 17:22 -0400
Re: Encapsulation unpythonic? Chris Angelico <rosuav@gmail.com> - 2013-08-18 01:59 +0100
Re: Encapsulation unpythonic? chaz2cry@gmail.com - 2013-08-22 19:12 -0700
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-30 10:43 -0700
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-31 02:35 +0000
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-30 23:07 -0700
Re: Encapsulation unpythonic? Marco Buttu <marco.buttu@gmail.com> - 2013-08-31 08:49 +0200
Re: Encapsulation unpythonic? Gary Herron <gherron@digipen.edu> - 2013-08-31 00:03 -0700
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-31 00:42 -0700
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-31 01:00 -0700
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-31 11:46 +0000
Re: Encapsulation unpythonic? Ned Batchelder <ned@nedbatchelder.com> - 2013-08-31 08:41 -0400
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-31 05:49 -0700
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-08-31 05:57 -0700
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-01 08:10 +0000
Re: Encapsulation unpythonic? Chris Angelico <rosuav@gmail.com> - 2013-09-01 18:21 +1000
Re: Encapsulation unpythonic? Fabrice Pombet <fp2161@gmail.com> - 2013-09-01 03:09 -0700
Re: Encapsulation unpythonic? Ethan Furman <ethan@stoneleaf.us> - 2013-09-01 11:42 -0700
Re: Encapsulation unpythonic? Roy Smith <roy@panix.com> - 2013-09-01 15:13 -0400
Re: Encapsulation unpythonic? Ethan Furman <ethan@stoneleaf.us> - 2013-09-01 13:33 -0700
Re: Encapsulation unpythonic? Tim Delaney <timothy.c.delaney@gmail.com> - 2013-09-02 07:54 +1000
Re: Encapsulation unpythonic? Roy Smith <roy@panix.com> - 2013-09-01 18:02 -0400
Re: Encapsulation unpythonic? Ethan Furman <ethan@stoneleaf.us> - 2013-09-01 17:24 -0700
Re: Encapsulation unpythonic? Roy Smith <roy@panix.com> - 2013-09-01 20:59 -0400
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-02 02:57 +0000
Re: Encapsulation unpythonic? Ethan Furman <ethan@stoneleaf.us> - 2013-09-01 21:15 -0700
Re: Encapsulation unpythonic? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-02 01:57 +0000
Re: Encapsulation unpythonic? Ben Finney <ben+python@benfinney.id.au> - 2013-09-02 09:32 +1000
Re: Encapsulation unpythonic? Roy Smith <roy@panix.com> - 2013-09-01 20:52 -0400
Re: Encapsulation unpythonic? "Rhodri James" <rhodri@wildebst.demon.co.uk> - 2013-09-03 00:29 +0100
Re: Encapsulation unpythonic? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-09-03 22:41 -0400
Re: Encapsulation unpythonic? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-08-31 13:31 -0400
Re: Encapsulation unpythonic? Tim Delaney <timothy.c.delaney@gmail.com> - 2013-09-01 03:47 +1000
Re: Encapsulation unpythonic? 88888 Dihedral <dihedral88888@gmail.com> - 2013-09-02 14:43 -0700
csiph-web