class cgi :cgi_environment -> output_type -> request_method -> cgi_argument list ->object..end
cgi env op meth args constructs Netcgi.cgi objects. The
environment #out_channel is wrapped into a transactional channel
or a discarding channel according to op (`Direct or
`Transactional) and request_method (`HEAD requests must only
return a header). For standard cases, when POST and PUT arguments
are available through a Netchannels.in_obj_channel, we recommend
you use Netcgi_common.cgi_with_args that will parse the
arguments for you and check preconditions.
Remark: You may think that the argument meth is superfluous as
it can be deduced from env#cgi_request_method. While it is true
for `DELETE, `GET, `HEAD and `POST, the `PUT takes a
Netcgi_common.cgi_argument parameter. Setting correctly this
parameter and decoding env#cgi_request_method is done for you by
Netcgi_common.cgi_with_args.
method argument : string -> cgi_argumentmethod argument_value : ?default:string -> string -> stringmethod argument_exists : string -> boolmethod multiple_argument : string -> cgi_argument listmethod arguments : cgi_argument listmethod environment : cgi_environmentmethod request_method : request_methodmethod finalize : unit -> unitmethod url : ?protocol:Nethttp.protocol ->
?with_authority:other_url_spec ->
?with_script_name:other_url_spec ->
?with_path_info:other_url_spec ->
?with_query_string:query_string_spec -> unit -> stringcgi_server_namecgi_server_portcgi_script_namecgi_path_infomethod set_header : ?status:Nethttp.http_status ->
?content_type:string ->
?content_length:int ->
?set_cookie:Nethttp.cookie list ->
?set_cookies:Cookie.t list ->
?cache:cache_control ->
?filename:string ->
?language:string ->
?script_type:string ->
?style_type:string -> ?fields:(string * string list) list -> unit -> unitmethod set_redirection_header : ?set_cookies:Cookie.t list ->
?fields:(string * string list) list -> string -> unitmethod output : Netchannels.trans_out_obj_channel#out_channel instead.method out_channel : Netchannels.trans_out_obj_channelmethod at_exit : (unit -> unit) -> unit