package ocsipersist-pgsql

  1. Overview
  2. Docs
type 'a monad = 'a Lwt_thread.t
type isolation = [
  1. | `Read_committed
  2. | `Read_uncommitted
  3. | `Repeatable_read
  4. | `Serializable
]
type access = [
  1. | `Read_only
  2. | `Read_write
]
exception Error of string
exception PostgreSQL_Error of string * (char * string) list
type connection_desc = PGOCaml_generic.Make(Lwt_thread).connection_desc = {
  1. user : string;
  2. port : int;
  3. password : string;
  4. host : [ `Hostname of string | `Unix_domain_socket_dir of string ];
  5. database : string;
}
val describe_connection : ?host:string -> ?port:int -> ?user:string -> ?password:string -> ?database:string -> ?unix_domain_socket_dir:string -> unit -> connection_desc
val connection_desc_to_string : connection_desc -> string
val connect : ?host:string -> ?port:int -> ?user:string -> ?password:string -> ?database:string -> ?unix_domain_socket_dir:string -> ?desc:connection_desc -> unit -> 'a t monad
val close : 'a t -> unit monad
val ping : 'a t -> unit monad
val alive : 'a t -> bool monad
val begin_work : ?isolation:isolation -> ?access:access -> ?deferrable:bool -> 'a t -> unit monad
val commit : 'a t -> unit monad
val rollback : 'a t -> unit monad
val transact : 'a t -> ?isolation:isolation -> ?access:access -> ?deferrable:bool -> ('a t -> 'b monad) -> 'b monad
val serial : 'a t -> string -> int64 monad
val serial4 : 'a t -> string -> int32 monad
val serial8 : 'a t -> string -> int64 monad
val max_message_length : int ref
val verbose : int ref
val set_private_data : 'a t -> 'a -> unit
val private_data : 'a t -> 'a
val uuid : 'a t -> string
type pa_pg_data = (string, bool) Hashtbl.t
type oid = int32
type param = string option
type result = string option
type row = result list
val prepare : 'a t -> query:string -> ?name:string -> ?types:oid list -> unit -> unit monad
val execute_rev : 'a t -> ?name:string -> ?portal:string -> params:param list -> unit -> row list monad
val execute : 'a t -> ?name:string -> ?portal:string -> params:param list -> unit -> row list monad
val cursor : 'a t -> ?name:string -> ?portal:string -> params:param list -> (row -> unit monad) -> unit monad
val close_statement : 'a t -> ?name:string -> unit -> unit monad
val close_portal : 'a t -> ?portal:string -> unit -> unit monad
val inject : 'a t -> ?name:string -> string -> row list monad
val alter : 'a t -> ?name:string -> string -> unit monad
type result_description = PGOCaml_generic.Make(Lwt_thread).result_description = {
  1. name : string;
  2. table : oid option;
  3. column : int option;
  4. field_type : oid;
  5. length : int;
  6. modifier : int32;
}
val show_result_description : result_description -> Ppx_deriving_runtime.string
type row_description = result_description list
val show_row_description : row_description -> Ppx_deriving_runtime.string
type params_description = param_description list
and param_description = PGOCaml_generic.Make(Lwt_thread).param_description = {
  1. param_type : oid;
}
val describe_statement : 'a t -> ?name:string -> unit -> (params_description * row_description option) monad
val describe_portal : 'a t -> ?portal:string -> unit -> row_description option monad
val name_of_type : oid -> string
type inet = Unix.inet_addr * int
type int16 = int
type bytea = string
type point = float * float
type hstore = (string * string option) list
type numeric = string
type uuid = string
type jsonb = string
type bool_array = bool option list
type int16_array = int16 option list
type int32_array = int32 option list
type int64_array = int64 option list
type string_array = string option list
type float_array = float option list
type timestamp_array = CalendarLib.Calendar.t option list
type uuid_array = string option list
val string_of_oid : oid -> string
val string_of_bool : bool -> string
val string_of_int : int -> string
val string_of_int16 : int16 -> string
val string_of_int32 : int32 -> string
val string_of_int64 : int64 -> string
val string_of_float : float -> string
val string_of_point : point -> string
val string_of_hstore : hstore -> string
val string_of_numeric : numeric -> string
val string_of_uuid : uuid -> string
val string_of_jsonb : jsonb -> string
val string_of_inet : inet -> string
val string_of_timestamp : CalendarLib.Calendar.t -> string
val string_of_timestamptz : timestamptz -> string
val string_of_date : CalendarLib.Date.t -> string
val string_of_time : CalendarLib.Time.t -> string
val string_of_interval : CalendarLib.Calendar.Period.t -> string
val string_of_bytea : bytea -> string
val string_of_string : string -> string
val string_of_unit : unit -> string
val string_of_bool_array : bool_array -> string
val string_of_int16_array : int16_array -> string
val string_of_int32_array : int32_array -> string
val string_of_int64_array : int64_array -> string
val string_of_string_array : string_array -> string
val string_of_bytea_array : string_array -> string
val string_of_float_array : float_array -> string
val string_of_timestamp_array : timestamp_array -> string
val string_of_arbitrary_array : ('a -> string) -> 'a option list -> string
val string_of_uuid_array : uuid_array -> string
val comment_src_loc : unit -> bool
val find_custom_typconvs : ?typnam:string -> ?lookin:string -> ?colnam:string -> ?argnam:string -> unit -> ((string * string) option, string) Rresult.result
val oid_of_string : string -> oid
val bool_of_string : string -> bool
val int_of_string : string -> int
val int16_of_string : string -> int16
val int32_of_string : string -> int32
val int64_of_string : string -> int64
val float_of_string : string -> float
val point_of_string : string -> point
val hstore_of_string : string -> hstore
val numeric_of_string : string -> numeric
val uuid_of_string : string -> uuid
val jsonb_of_string : string -> jsonb
val inet_of_string : string -> inet
val timestamp_of_string : string -> CalendarLib.Calendar.t
val timestamptz_of_string : string -> timestamptz
val date_of_string : string -> CalendarLib.Date.t
val time_of_string : string -> CalendarLib.Time.t
val interval_of_string : string -> CalendarLib.Calendar.Period.t
val bytea_of_string : string -> bytea
val unit_of_string : string -> unit
val bool_array_of_string : string -> bool_array
val int16_array_of_string : string -> int16_array
val int32_array_of_string : string -> int32_array
val int64_array_of_string : string -> int64_array
val string_array_of_string : string -> string_array
val float_array_of_string : string -> float_array
val timestamp_array_of_string : string -> timestamp_array
val arbitrary_array_of_string : (string -> 'a) -> string -> 'a option list
val bind : 'a monad -> ('a -> 'b monad) -> 'b monad
val return : 'a -> 'a monad
OCaml

Innovation. Community. Security.