a dumb question...

Ned Konz ned at bike-nomad.com
Tue Jun 25 18:46:19 UTC 2002


On Tuesday 25 June 2002 11:22 am, Mayer Goldberg wrote:

> Sorry for the dumb question, I'm looking at Stream>>{close, sleep}
> and I can't understand why the method bodies are empty rather than
> self subclassResponsibility.

Because the default is to do nothing. The close method is there for 
compatibility between FileStream classes (where it is defined as 
subclassResponsibility) and other Streams (which typically do nothing 
at all).

Same with RemoteFileStream>>sleep; it's meaningless for other Streams, 
so there is a default method that does nothing in Stream.

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE




More information about the Squeak-dev mailing list