Binary text file to reference. The file does not to exist
Opens a stream in Write
, Read
or Overwrite
mode
(default: 7) Character set of the text. See more details on charset
Creates a textStream.
// The file does not have to exist
var myFile = new File( 'PROJECT/my-streamed-file.js' );
var myStream = new TextStream( file, 'write' );
// Creates the file if it does not exist
myStream.write( 'Hello '+ Date.now() +' !\n' );
// Important to close the stream every time.
myStream.close();
Binary text file to reference. The file does not to exist
Opens a stream in Write
, Read
or Overwrite
mode
(default: 7) Character set of the text. See more details on charset
Creates a textStream.
// The file does not have to exist var myStream = new TextStream( 'PROJECT/my-streamed-file.js', 'write' ); // Creates the file if it does not exist myStream.write( 'Hello '+ Date.now() +' !\n' ); // Important to close the stream every time. myStream.close();