Relative Content

Tag Archive for pythonclassstaticdecorator

Python: Regular method and static method with same name

Introduction I have a Python class, which contains a number of methods. I want one of those methods to have a static counterpart—that is, a static method with the same name—which can handle more arguments. After some searching, I have found that I can use the @staticmethod decorator to create a static method. Problem For […]