Newsgroups: comp.lang.smalltalk
Path: cantaloupe.srv.cs.cmu.edu!fs7.ece.cmu.edu!kinky.eng.gtefsd.com!europa.eng.gtefsd.com!howland.reston.ans.net!torn!nott!cunews!dbuck
From: dbuck@superior.carleton.ca (Dave Buck)
Subject: Re: Novice Smalltalk question about File class
Message-ID: <D384px.Eyp@cunews.carleton.ca>
Sender: news@cunews.carleton.ca (News Administrator)
Organization: Carleton University, Ottawa, Canada
References: <BK.BW.791441830.1103527590.kchen@yvr.cyberstore.ca>
Date: Mon, 30 Jan 1995 15:08:21 GMT
Lines: 31

In article <BK.BW.791441830.1103527590.kchen@yvr.cyberstore.ca>,
Kevin Chen  <kchen@yvr.cyberstore.ca> wrote:
>I'm currently using Smalltalk 3.0 for DOS to learn the language & I'm trying
>to figure out the following example:
>
>input := File pathName: 'go'.
>output := File pathName: 'junk'.
>[input atEnd]
>    whileFalse: [output nextPut: input next].
>
>
>My question regard the File class.  I can't find the atEnd method or
>the nextPut method in the File class when I use the class browser.
>Yet the code works when I evaluate it.  
>
>How can the input & output objects handle the messages?  

The method File>>pathName actually gives you back a FileStream on a
File.  FileStreams have these methods.


David Buck
dbuck@ccs.carleton.ca

_____________________________________________________________________
| David K. Buck                 | My employer is not responsible for|
| dbuck@ccs.carleton.ca         | my opinions.  In fact, they don't |
| Original author of DKBTrace   | even know I have this account.    |
|_______________________________|___________________________________|
 

