next up previous contents index
Next: Debugging and Tracing Programs Up: Built-in predicates Previous: User Toplevel Manipulation   Contents   Index

Creating a Protocol of the User Interaction

SWI-Prolog offers the possibility to log the interaction with the user on a file.2.14All Prolog interaction, including warnings and tracer output, are written on the protocol file.

protocol1+File Start protocolling on file File. If there is already a protocol file open then close it first. If File exists it is truncated. protocola1+File Equivalent to protocol1, but does not truncate the File if it exists. noprotocol0 Stop making a protocol of the user interaction. Pending output is flushed on the file. protocolling1-File Succeeds if a protocol was started with protocol1 or protocola1 and unifies File with the current protocol output file.



Dr. Richard Botting 2001-12-12