Plasma GitLab Archive
Projects Blog Knowledge

Class Netchannels.output_command


class output_command : ?onclose:unit -> unit -> string -> out_obj_channel
Runs the command with /bin/sh, and data written to the channel is piped to stdin of the command.

The method pos_out returns the number of written octets.

When close_out is invoked, the subprocess is waited for. If the process exits with code 0, the method returns normally. Otherwise, the exception Command_failure is raised.


onclose : this function is called when the close_out method is invoked, just after the underlying descriptor has been closed.

This web site is published by Informatikbüro Gerd Stolpmann
Powered by Caml