AT&T Home | AT&T Labs | Research
AT&T Labs, Inc. - Research

The Yoix® Scripting Language

Home | What's New | Grammar | Documentation | Download | License | YChart | YDAT | YWAIT | Byzgraf | FAQs
readLine (Stream stream) yoix.io
 
Reads characters from stream up to the next newline or end-of-stream, stores them in a new string, and returns that string or NULL if there is nothing to read or an error occurs.
 
 Example:   On a UNIX-like system the program,
import yoix.io.*;

String  line;
File    file;

if ((file = open("/etc/passwd", "r")) != NULL) {
    while ((line = readLine(file)) != NULL)
        writeLine(stdout, line);
    close(file);
}
copies the system password file to standard output, one line at a time.
 
 Return:   String
 
 See Also:   read, readChar, readStream, ready

 

Yoix is a registered trademark of AT&T Inc.