static python classes ?
google at gakman.com
google at gakman.com
Tue Jun 19 08:15:55 EDT 2007
On Jun 19, 10:00 pm, Tom Gur <gur.... at gmail.com> wrote:
> Hi,
>
> I'm new to python, and I can't seem to find in the docs how to create
> the python equivalent of what's called in most OOP languages "static
> classes", can you give me a hint ?
Look for @staticmethod in http://docs.python.org/lib/built-in-funcs.html
Example:
class C:
@staticmethod
def f(arg1, arg2, ...): ...
--
Gerald Kaszuba
http://geraldkaszuba.com
More information about the Python-list
mailing list