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


Groups > comp.lang.python > #53310

Best practice for generalizing and documenting each method's behaviour

X-Received by 10.58.255.74 with SMTP id ao10mr233883ved.38.1377885869064; Fri, 30 Aug 2013 11:04:29 -0700 (PDT)
X-Received by 10.49.133.201 with SMTP id pe9mr432073qeb.6.1377885868986; Fri, 30 Aug 2013 11:04:28 -0700 (PDT)
Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!fx3no6215180qab.0!news-out.google.com!p7ni0qas.0!nntp.google.com!fx3no6215175qab.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail
Newsgroups comp.lang.python
Date Fri, 30 Aug 2013 11:04:28 -0700 (PDT)
Complaints-To groups-abuse@google.com
Injection-Info glegroupsg2000goo.googlegroups.com; posting-host=70.71.114.117; posting-account=u66fiwkAAAAEah1VSHz_oNsXn41pEQvE
NNTP-Posting-Host 70.71.114.117
User-Agent G2/1.0
MIME-Version 1.0
Message-ID <b9541a34-734c-4402-a097-340781dfe34e@googlegroups.com> (permalink)
Subject Best practice for generalizing and documenting each method's behaviour
From niubao56@gmail.com
Injection-Date Fri, 30 Aug 2013 18:04:28 +0000
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding quoted-printable
Xref csiph.com comp.lang.python:53310

Show key headers only | View raw


I'm starting a small project coding in Python as I learn the ropes. As the project grows bigger, there are more and more overlapping and even redundant methods. For example, several classes have a checkAndClean_obj_state() method. If just one or two such classes, it is easy to analyze the behaviour of them and design the optimal interaction for all objects. However, when there are many of such classes, exactly at what point to invoke check and clean behaviour becomes a little blurred. There is a desperate need for generalizing and documenting the behaviour of each such class, preferably in a flowchart. I'm currently doing the flowchart manually but the job becomes a bit overwhelming.

I wonder what Python pros are using for analyzing and documenting classes/functions behaviours and interactions? Is UML the only way? Personally I found UML is a bit overkill for a one person project, but I'm not sure if it is the right direction. I'd appreciate any insight. Many thanks.

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


Thread

Best practice for generalizing and documenting each method's behaviour niubao56@gmail.com - 2013-08-30 11:04 -0700
  Re: Best practice for generalizing and documenting each method's behaviour Fábio Santos <fabiosantosart@gmail.com> - 2013-09-01 03:31 +0100
  Re: Best practice for generalizing and documenting each method's behaviour Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-01 04:29 +0000

csiph-web