# HG changeset patch # User Claus Gittinger # Date 1017076720 -3600 # Node ID 92a666c5b1047ec2cc7b82cc8e541d6aa154d033 # Parent 2fa4b6ba2c134640d30997249118dfc6ec5c40ba dolphin compatibility diff -r 2fa4b6ba2c13 -r 92a666c5b104 ExternalStream.st --- a/ExternalStream.st Mon Mar 25 18:11:37 2002 +0100 +++ b/ExternalStream.st Mon Mar 25 18:18:40 2002 +0100 @@ -1859,6 +1859,12 @@ ^ false ! ! +!ExternalStream methodsFor:'Compatibility - Dolphin'! + +beText + self text +! ! + !ExternalStream methodsFor:'Compatibility - Squeak'! nextInto:aByteArrayOrString @@ -5715,6 +5721,6 @@ !ExternalStream class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/libbasic/ExternalStream.st,v 1.234 2002-03-11 10:49:22 stefan Exp $' + ^ '$Header: /cvs/stx/stx/libbasic/ExternalStream.st,v 1.235 2002-03-25 17:18:40 cg Exp $' ! ! ExternalStream initialize! diff -r 2fa4b6ba2c13 -r 92a666c5b104 FileStream.st --- a/FileStream.st Mon Mar 25 18:11:37 2002 +0100 +++ b/FileStream.st Mon Mar 25 18:18:40 2002 +0100 @@ -478,6 +478,37 @@ s binary ]. ^ s +! + +write:filename mode:modeSymbol + "return a writable FileStream for the file named filename, aString. + The modeSymbol controls how the file is opened; currently supported are: + #append + " + + modeSymbol == #append ifTrue:[ + ^ self appendingOldFileNamed:filename + ]. + self halt:'unsupported mode'. + ^ nil +! + +write:filename text:textModeBoolean + "return a writable FileStream for the file named filename, aString. + If the argument, text is false, the stream is setup to write binary bytes, + if false, it writes characters." + + |s| + + s := self fileNamed:filename. + s notNil ifTrue:[ + textModeBoolean ifTrue:[ + s text + ] ifFalse:[ + s binary + ] + ]. + ^ s ! ! !FileStream class methodsFor:'Compatibility - Squeak'! @@ -1319,6 +1350,6 @@ !FileStream class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/libbasic/FileStream.st,v 1.83 2002-03-14 23:03:10 cg Exp $' + ^ '$Header: /cvs/stx/stx/libbasic/FileStream.st,v 1.84 2002-03-25 17:18:18 cg Exp $' ! ! FileStream initialize!