package lemonade-sqlite

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type +'a t
val bind : 'a t -> ('a -> 'b t) -> 'b t
val return : 'a -> 'a t
val apply : ('a -> 'b) t -> 'a t -> 'b t
val join : 'a t t -> 'a t
val map : ('a -> 'b) -> 'a t -> 'b t
val bind2 : 'a t -> 'b t -> ('a -> 'b -> 'c t) -> 'c t
val bind3 : 'a t -> 'b t -> 'c t -> ('a -> 'b -> 'c -> 'd t) -> 'd t
val bind4 : 'a t -> 'b t -> 'c t -> 'd t -> ('a -> 'b -> 'c -> 'd -> 'e t) -> 'e t
val map2 : ('a -> 'b -> 'c) -> 'a t -> 'b t -> 'c t
val map3 : ('a -> 'b -> 'c -> 'd) -> 'a t -> 'b t -> 'c t -> 'd t
val map4 : ('a -> 'b -> 'c -> 'd -> 'e) -> 'a t -> 'b t -> 'c t -> 'd t -> 'e t
val dist : 'a t list -> 'a list t
val ignore : 'a t -> unit t
val filter : ('a -> bool t) -> 'a t list -> 'a list t
val only_if : bool -> unit t -> unit t
val unless : bool -> unit t -> unit t
val catch : (unit -> 'a t) -> (exn -> 'a t) -> 'a t
module Infix : sig ... end
type error = string * string
type !'a outcome =
  1. | Success of 'a
  2. | Error of error
val run : 'a t -> 'a outcome
val error : error -> 'a t
val recover : 'a t -> (error -> 'a t) -> 'a t
type handle
module S : sig ... end
val opendb : ?init:string -> string -> handle
val closedb : handle -> unit
val withdb : ?init:string -> string -> (handle -> 'a) -> 'a
type row = data array
and data = Sqlite3.Data.t =
  1. | NONE
  2. | NULL
  3. | INT of int64
  4. | FLOAT of float
  5. | TEXT of string
  6. | BLOB of string
type statement
type binding
val query : statement -> handle -> row S.t
val one : row S.t -> row t
val maybe : row S.t -> row option t
val project : ('a -> 'b * 'c) -> 'a S.t -> ('b * 'c list) S.t
val exec : statement -> handle -> unit t
val insert : statement S.t -> handle -> unit t
val statement : string -> statement
val rowid_binding : int64 ref -> 'a -> data
val bindings : (string * ('a -> data)) list -> 'a S.t -> binding S.t
val bindings_apply : ?rowid:int64 ref -> binding S.t -> statement -> statement S.t
val pp_print_data : Format.formatter -> data -> unit
val pp_print_row : Format.formatter -> row -> unit