Dear Robert, > I've also modified the code in File.oz and it works fine also. I didn't > read yet the code of File.oz very carefully but it seems to use the url > for ReadList, ReadListLazy and ReadOpen (thus for all the read > operations) and the name for all the write operations (WriteList, > WriteOpen, WriteAppend). I wonder why.
I believe the reasons is this: An URL can be any address involving "http", "ftp", local files and possibly other schemes. Often the contents at such an URL can be READ, but not WRITTEN. E.g. we can read from a WWW address but we cannot write to it. Therefore it makes sense to use URLs for reading and filenames for writing. In light of this, maybe Mozart should be changed to allow "stdin" as a valid URL. > I don't understand the code for > ReadBlock and Write but it surely is because I'm not far enough in my > study of Oz. "Write" just writes a string to the file whose handle is stored in the global cell W, i.e. the file which has previously been opened with WriteOpen or WriteAppend. ReadBlock involves difference lists which are explained somewhere else in the book. > By the way, when I run wordapp, after closing the window, I have to use > "ctrl-C" to go back to the command line prompt. I suppose there is a > better way to do this? Yes, see here: http://lists.gforge.info.ucl.ac.be/pipermail/mozart-users/2005/006073.html Cheers, Wolfgang -- GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT! Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01 _________________________________________________________________________________ mozart-users mailing list [email protected] http://www.mozart-oz.org/mailman/listinfo/mozart-users
