next up previous contents index
Next: Term I/O Up: Input and Output Previous: File Handling   Contents   Index

Character I/O

nl

A new line character is sent to the current output stream.

nl(+Stream)

A new line character is sent to the designated output stream.

get0(?N)

N is the ASCII code of the next character read from the current input stream (regarded as a text stream). If the current input stream reaches its end of file, a -1 is returned.

Compatibility Note: Unlike other Prologs, such as C-Prolog, the input stream is not closed on encountering the end-of-file character.

get(?N)

N is the ASCII code of the next non-blank printable character from the current input stream (regarded as a text stream). If the current input stream reaches its end of file, a -1 is returned.

Compatibility Note: Unlike other Prologs, such as C-Prolog, the input stream is not closed on encountering the end-of-file character.

get_code(?N)


get_code(+Stream,?N)

N is the ASCII code of the next character from the current input stream or from Stream. The semantics of these predicates are based on that of get0/1 and do not conform in all cases to the ISO standard.

get_char(?Char)


get_char(+Stream,?Char)

Char is the next ASCII character from the current input stream or from Stream. The semantics of these predicates are based on that of get0/1 and do not conform in all cases to the ISO standard.

put(+N)

Puts the ASCII character code N to the current output stream.

Exceptions:

instantiation_error
N is not instantiated at the time of the call.
type_error
N is not an integer at the time of the call.

put_code(+N)


put_code(+Stream,+N)

Puts the ASCII character code N to the current output stream or to Stream. The semantics of these predicates are based on that of put/1 and do not conform in all cases to the ISO standard.

put_char(+Char)


put_char(+Stream,+Char)

Puts the ASCII code of the character Char to the current output stream or to Stream. The semantics of these predicates are based on that of put/1 and do not conform in all cases to the ISO standard.

tab(+N)

Puts N spaces to the current output stream.

Exceptions:

instantiation_error
N is not instantiated at the time of the call.
type_error
N is not an integer at the time of the call.


next up previous contents index
Next: Term I/O Up: Input and Output Previous: File Handling   Contents   Index
Luis Fernando P. de Castro 2003-06-27