JAVA/CORBA CLASSES


Working with streams of data
The Stream class lets you examine and manipulate files as streams of binary or character data. Use the createStream method in the Session class to create a new Stream object.

The following methods access the Stream properties:


Use the write or writeText method to put data into a stream. Use the read or readText method to get data from a stream. Use the truncate method to delete the contents of a stream.

Use the open method to associate a stream with a file and to copy the file contents into the stream. If the file does not exist, the open method creates a new file. Use any of the read or write methods to process the data. Use the close method to release system resources associated with the stream.

Use the getContents method and setContents method to move contents back and forth between a stream and a java.io stream.

See Also