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


Groups > comp.lang.python > #64098

Re: Python glob and raw string

From Neil Cerutti <neilc@norwich.edu>
Subject Re: Python glob and raw string
Date 2014-01-16 18:45 +0000
Organization Norwich University
References <6d3dd7d7-6836-4b55-9d1c-9e70e18b66fd@googlegroups.com> <lb97i6$8od$1@ger.gmane.org> <CAPTjJmqz6fEgpPkNbohaxkWDw+Z1aamXOpH5NNHzV8TtXXQB2g@mail.gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.5598.1389897976.18130.python-list@python.org> (permalink)

Show all headers | View raw


On 2014-01-16, Chris Angelico <rosuav@gmail.com> wrote:
>> Hmmm... I might be doing too much in __init__. ;)
>
> Hmm, why is it even a class? :) I guess you elided all the
> stuff that makes it impractical to just use a non-class
> function.

I didn't remove anything that makes it obviously class-worthy,
just timestamp checking, and several dicts and sets to store
data.

The original version of that code is just a set of three
functions, but the return result of that version was a single
dict. Once the return value got complicated enough to require
building up a class instance, it became a convenient place to
hang the functions.

-- 
Neil Cerutti

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


Thread

Python glob and raw string Xaxa Urtiz <urtizvereaxaxa@gmail.com> - 2014-01-16 08:49 -0800
  Re: Python glob and raw string Xaxa Urtiz <urtizvereaxaxa@gmail.com> - 2014-01-16 10:03 -0800
  Re: Python glob and raw string Neil Cerutti <neilc@norwich.edu> - 2014-01-16 18:14 +0000
    Re: Python glob and raw string Xaxa Urtiz <urtizvereaxaxa@gmail.com> - 2014-01-17 08:45 -0800
      Re: Python glob and raw string Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-17 17:38 +0000
  Re: Python glob and raw string Chris Angelico <rosuav@gmail.com> - 2014-01-17 05:19 +1100
  Re: Python glob and raw string Neil Cerutti <neilc@norwich.edu> - 2014-01-16 18:45 +0000

csiph-web