package devkit

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Httpev.ArgsSource

functor version of Param because somebody thought it is good idea

Parameters

module T : sig ... end

Signature

Sourceval req : request
Sourceexception Bad of string
Sourceval get : string -> string option

Get optional parameter.

  • returns

    None if parameter is missing

Sourceval str : ?default:string -> string -> string

Get required parameter.

  • raises Bad

    if parameter is missing and no default provided

Sourceval get_int : string -> int option

Get optional integer parameter

Sourceval int : ?default:int -> string -> int

Get integer parameter.

  • raises Bad

    if parameter is missing and no default provided

Sourceval bool : ?default:bool -> string -> bool

Get boolean parameter.

  • returns

    true when parameter value is "true", false otherwise.

    @raise Bad

    if missing and no default provided.

Sourceval float : ?default:float -> string -> float
Sourceval int64 : ?default:int64 -> string -> int64
Sourceval array : string -> string list
  • parameter name

    array name without brackets e.g. array "x" to extract x from /request?x=1&x=2

OCaml

Innovation. Community. Security.