What do you call a class not intended to be instantiated

Tim Rowe digitig at gmail.com
Mon Sep 22 13:04:50 CEST 2008

2008/9/22 Bruno Desthuilliers <bruno.42.desthuilliers at websiteburo.invalid>:
> Steven D'Aprano a écrit :
>> On Mon, 22 Sep 2008 10:11:58 +0200, Bruno Desthuilliers wrote:
>>> Steven D'Aprano a écrit :
>>>> I have a class which is not intended to be instantiated. Instead of
>>>> using the class to creating an instance and then operate on it, I use
>>>> the class directly, with classmethods. Essentially, the class is used
>>>> as a function that keeps state from one call to the next.

Sounds to me like a functor, aka a function object:

Tim Rowe

More information about the Python-list mailing list