Node:Hookable Standard Streams, Previous:Defining a New Stream, Up:SICStus Streams
As of release 3.7, the standard I/O streams (input, output, and error) are hookable, i.e. the streams can be redefined by the user.
SP_UserStreamHook *SP_set_user_stream_hook(SP_UserStreamHook *hook)
hook
.
SP_UserStreamPostHook *SP_set_user_stream_post_hook(SP_UserStreamPostHook *hook)
hook
.
These hook functions must be called before SP_initialize()
(see Initializing the Prolog Engine). In custom built development
systems, they may be called in the hook function SU_initialize()
.
See The Application Builder.