🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.python
Article #8690

Re: Największy problem Pythona.

#8690
From: Daniel Mróz
Date: Thu, 12 May 2005 09:26
16 lines
2117 bytes
Maciej Pietrzak napisał(a):
>>>bezmyślnego (w pisaniu zmyślnym IDE nie pomaga wcale). Dobrym
>>>przykładem są standardowe gettery i settery: w javowych IDE są często
>>>generowane automatycznie, w pythonowych IDE nie są, ale ich użycie
>>>jest w ogóle błędem.
>>Mozna prosic o rozwiniecie?
> Jeśli chcemy zmiecić wiek pracownika e, to robimy e.age = 14, a nie
> e.setage(14). To jest naturalne, ponieważ to co chcemy zrobić, to jest:
> "zmienić wartość e.age", a nie "wywołać metodę e ustawiającą wiek z
> parametrem 14". Zamiast deklarować atrybut i pisać dwie metody nie
No tak, ale co z kontrola poprawnosci danych? setage() moze nam 
sprawdzic czy przypadkiem ktos zamiast 14 nie przekazuje "czternascie".


Pozdrawiam
Beorn
Technical Details
Message-ID: <d5v7fu$75t$1@news.supermedia.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!mat.uni.torun.pl!news.man.torun.pl!newsfeed.pionier.net.pl!news.supermedia.pl!not-for-mail
References: <jsq2enrcpp4r$.nmpn8bgh83ge.dlg@40tude.net> <d5r1l6$flm$1@nemesis.news.tpi.pl> <1njwce3cqj46q.11f4hsu79ksgd.dlg@40tude.net> <1gvuz1q6mpswb.2m8e9kggxehl.dlg@40tude.net> <d5r6le$msg$1@nemesis.news.tpi.pl> <1wa07hpw18hk1.effbya3x2hyr$.dlg@40tude.net> <d5sd5s$ctc$1@gw.magellan.net.pl> <d5v015$3ta$1@nemesis.news.tpi.pl> <d5v2tv$4l7$1@news.supermedia.pl> <d5v5so$2bv$1@achot.icm.edu.pl>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!mat.uni.torun.pl!news.man.torun.pl!newsfeed.pionier.net.pl!news.supermedia.pl!not-for-mail
From: Daniel Mróz <beorn@alpha.pl>
Newsgroups: pl.comp.lang.python
Subject: Re: Największy problem Pythona.
Date: Thu, 12 May 2005 11:26:28 +0200
Organization: SuperMedia - http://www.sm.pl
Lines: 16
Message-ID: <d5v7fu$75t$1@news.supermedia.pl>
References: <jsq2enrcpp4r$.nmpn8bgh83ge.dlg@40tude.net> <d5r1l6$flm$1@nemesis.news.tpi.pl> <1njwce3cqj46q.11f4hsu79ksgd.dlg@40tude.net> <1gvuz1q6mpswb.2m8e9kggxehl.dlg@40tude.net> <d5r6le$msg$1@nemesis.news.tpi.pl> <1wa07hpw18hk1.effbya3x2hyr$.dlg@40tude.net> <d5sd5s$ctc$1@gw.magellan.net.pl> <d5v015$3ta$1@nemesis.news.tpi.pl> <d5v2tv$4l7$1@news.supermedia.pl> <d5v5so$2bv$1@achot.icm.edu.pl>
NNTP-Posting-Host: ztmsen.cza.warszawa.supermedia.pl
Mime-Version: 1.0
X-Trace: news.supermedia.pl 1115889982 7357 212.75.102.170 (12 May 2005 09:26:22 GMT)
X-Complaints-To: abuse@supermedia.pl
NNTP-Posting-Date: Thu, 12 May 2005 09:26:22 +0000 (UTC)
X-Enigmail-Supports: pgp-inline, pgp-mime
In-Reply-To: <d5v5so$2bv$1@achot.icm.edu.pl>
X-Accept-Language: pl, en-us, en
User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206)
X-Enigmail-Version: 0.89.5.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit