[Tutor] Are Empty "Placeholder" Functions possible?
Gooch, John
John.Gooch at echostar.com
Thu May 26 17:42:47 CEST 2005
Is there a way to create an empty function definition with no lines of code
in it? In my coding style I will often do this ( in other languages ) for
RAD just to remind myself that I will need to implement the function later.
Example: For a file handling class, I may need functions such as
copy,delete,move,etc so I want to start off with:
class FileHandler:
def __init__(self):
def copy(self):
def delete(self):
.
.
.
then in my driver/aka testing file:
import FileHandler
def main()
MyHandler = FileHandler()
print "Handler Created."
main()
Right now, this won't work as the compliler will error on functions with
nothing in them. Is there a "no-op", "do nothing", or some similar command I
can put in the empty functions to keep the compiler/interpreter from
erroring on them? This would really help speed up my development so that I
can create the class skeleton quickly and then implement each function and
test it as I go.
Thank You,
John A. Gooch
Systems Administrator
IT - Tools
EchoStar Satellite L.L.C.
9601 S. Meridian Blvd.
Englewood, CO 80112
Desk: 720-514-5708
More information about the Tutor
mailing list