3 ms·
That's a thing you can also do in Python: class MyObject: def doThing(self, value: str) -> None: # whatever pass obj =
by comfydragon 6y ago
That's a thing you can also do in Python:
class MyObject:
def doThing(self, value: str) -> None:
# whatever
pass
obj = MyObject()
obj.doThing("value!")
MyObject.doThing(obj, "a different value!")
The only difference is that doThing is namespaced to the MyObject class.