[Tutor] Here is the whole script I'm having issues with.
alan.gauld@bt.com
alan.gauld@bt.com
Mon, 26 Aug 2002 11:57:55 +0100
> However, a quick chek with vi showed that the indentation was
> indeed off on the line story. I fixed it and now the classes load.
Ah! Thats a relief.
> >> class Html:
> >> def __init__(self, address):
> >> def connect(self):
> x.connect() afterwards and the connect method runs. Actually,
> If I run an instance of the las method in the class, all of
> the methods in the class are run.
I assume thats a deliberate design decision on your part?
ie You wrote a method to excercise all of the other methods?
> So if I add self to the method variables as you suggest and run:
> x = Html("some address here")
> Will the whole class run straight through?
Not sure what you mean by the whole class running straight through.
The class definition will run through without any difference.
When you call a method the data within that method will be
stored within the instances. What else do you think might happen?
> Also, now that I have re-edited the script, would it be Ok to
> post for everyone to check out? Is anyone even interested in
> this script?
Assuming its not thousands odf lines long then yes that seems
to be an accepted process. Of course hoew many take time to
read it all will be variable...
Alan g.
PS. Catching up on 4 digests so this may be dealt with already...