[Pharo-project] Re: [squeak-dev] ANN Rio now supports ftp
Rio has now been refactored so as to be cleaner and to avoid any such tricks as doesNotUnderstand: best regards Keith
*News:*
Rio has finally made it to (roughly) where it was planned to be all along. File manipulations that work locally should now also work remotely.
e.g.
dir := 'ftp://squeak:viewpoints@squeak.warwick.st/test/test/test' asRio mkpath. file := dir / 'hello.txt' contents: 'hello world'.
next := file rename nextVersion. next name. { hello.1.txt } next fileSize. {11}
next copyTo: 'local.txt'
*Limitations:*
Although you can obtain read or writeStreams directly into the remote file, it is not random access (yet?) therefore you cant currently write directly to the write stream of a remote gzip file (which you can do locally)
*More Info:*
http://wiki.squeak.org/squeak/5929
cheers
Keith ------------------------------------------------------------------------
Now that the architecture for Rio is complete. Its time for a vote! Current usage.... 'someDir/someFile' asRio -> instance of Rio. 'someDir/newDir' asRio mkdir -> instance of Rio. 'someDir/file.zip' asRio zip -> instance of RioArchive. Could change to usage..... 'someDir/someFile' asFile. -> instance of File. 'someDir/newDir' asDirectory -> instance of Directory. 'someDir/file.zip' asFile zip -> instance of FileArchive. I like the original #asRio, and I wonder if there are any other smalltalks which already use #asFile and #asDirectory, and classes File and Directory. Nevertheless I can see why people would prefer the latter. votes? Keith
participants (1)
-
Keith Hodges