Module Pqueue.MakeMax
Functor building an implementation of the max-priority queue structure given a totally ordered type for elements.
Parameters
ocaml
module E : OrderedTypereasonml
module E: OrderedTypeSignature
ocaml
type treasonml
type t;ocaml
val create : unit -> treasonml
let create: unit => t;ocaml
val length : t -> intreasonml
let length: t => int;ocaml
val is_empty : t -> boolreasonml
let is_empty: t => bool;ocaml
val add : t -> E.t -> unitreasonml
let add: t => E.t => unit;ocaml
val add_iter : t -> ((E.t -> unit) -> 'x -> unit) -> 'x -> unitreasonml
let add_iter: t => ((E.t => unit) => 'x => unit) => 'x => unit;ocaml
val max_elt : t -> E.t optionreasonml
let max_elt: t => option(E.t);ocaml
val get_max_elt : t -> E.treasonml
let get_max_elt: t => E.t;ocaml
val pop_max : t -> E.t optionreasonml
let pop_max: t => option(E.t);ocaml
val remove_max : t -> unitreasonml
let remove_max: t => unit;ocaml
val clear : t -> unitreasonml
let clear: t => unit;ocaml
val copy : t -> treasonml
let copy: t => t;ocaml
val of_array : E.t array -> treasonml
let of_array: array(E.t) => t;ocaml
val of_list : E.t list -> treasonml
let of_list: list(E.t) => t;ocaml
val of_iter : ((E.t -> unit) -> 'x -> unit) -> 'x -> treasonml
let of_iter: ((E.t => unit) => 'x => unit) => 'x => t;ocaml
val iter_unordered : (E.t -> unit) -> t -> unitreasonml
let iter_unordered: (E.t => unit) => t => unit;ocaml
val fold_unordered : ('acc -> E.t -> 'acc) -> 'acc -> t -> 'accreasonml
let fold_unordered: ('acc => E.t => 'acc) => 'acc => t => 'acc;