package batteries

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type 'a t = 'a BatEnum.t
module type Enumerable = sig ... end
type 'a enumerable = 'a t
type 'a mappable = 'a t
val iter : ('a -> unit) -> 'a t -> unit
val iter2 : ('a -> 'b -> unit) -> 'a t -> 'b t -> unit
val exists : ('a -> bool) -> 'a t -> bool
val for_all : ('a -> bool) -> 'a t -> bool
val fold : ('b -> 'a -> 'b) -> 'b -> 'a t -> 'b
val reduce : ('a -> 'a -> 'a) -> 'a t -> 'a
val sum : int t -> int
val fsum : float t -> float
val kahan_sum : float t -> float
val fold2 : ('a -> 'b -> 'c -> 'c) -> 'c -> 'a t -> 'b t -> 'c
val scanl : ('b -> 'a -> 'b) -> 'b -> 'a t -> 'b t
val scan : ('a -> 'a -> 'a) -> 'a t -> 'a t
val iteri : (int -> 'a -> unit) -> 'a t -> unit
val iter2i : (int -> 'a -> 'b -> unit) -> 'a t -> 'b t -> unit
val foldi : (int -> 'a -> 'b -> 'b) -> 'b -> 'a t -> 'b
val fold2i : (int -> 'a -> 'b -> 'c -> 'c) -> 'c -> 'a t -> 'b t -> 'c
val find_map : ('a -> 'b option) -> 'a t -> 'b
val is_empty : 'a t -> bool
val peek : 'a t -> 'a option
val get : 'a t -> 'a option
val get_exn : 'a t -> 'a
val push : 'a t -> 'a -> unit
val junk : 'a t -> unit
val clone : 'a t -> 'a t
val force : 'a t -> unit
val take : int -> 'a t -> 'a t
val drop : int -> 'a t -> unit
val skip : int -> 'a t -> 'a t
val take_while : ('a -> bool) -> 'a t -> 'a t
val drop_while : ('a -> bool) -> 'a t -> 'a t
val span : ('a -> bool) -> 'a t -> 'a t * 'a t
val break : ('a -> bool) -> 'a t -> 'a t * 'a t
val group : ('a -> 'b) -> 'a t -> 'a t t
val group_by : ('a -> 'a -> bool) -> 'a t -> 'a t t
val clump : int -> ('a -> unit) -> (unit -> 'b) -> 'a t -> 'b t
val cartesian_product : 'a t -> 'b t -> ('a * 'b) t
val map : ('a -> 'b) -> 'a t -> 'b t
val mapi : (int -> 'a -> 'b) -> 'a t -> 'b t
val filter : ('a -> bool) -> 'a t -> 'a t
val filter_map : ('a -> 'b option) -> 'a t -> 'b t
val append : 'a t -> 'a t -> 'a t
val prefix_action : (unit -> unit) -> 'a t -> 'a t
val suffix_action : (unit -> unit) -> 'a t -> 'a t
val concat : 'a t t -> 'a t
val flatten : 'a t t -> 'a t
val concat_map : ('a -> 'b t) -> 'a t -> 'b t
exception No_more_elements
exception Infinite_enum
val empty : unit -> 'a t
val make : next:(unit -> 'a) -> count:(unit -> int) -> clone:(unit -> 'a t) -> 'a t
val from : (unit -> 'a) -> 'a t
val from_while : (unit -> 'a option) -> 'a t
val from_loop : 'b -> ('b -> 'a * 'b) -> 'a t
val seq : 'a -> ('a -> 'a) -> ('a -> bool) -> 'a t
val unfold : 'b -> ('b -> ('a * 'b) option) -> 'a t
val init : int -> (int -> 'a) -> 'a t
val singleton : 'a -> 'a t
val repeat : ?times:int -> 'a -> 'a t
val cycle : ?times:int -> 'a t -> 'a t
val delay : (unit -> 'a t) -> 'a t
val to_object : 'a t -> < clone : 'b ; count : int ; next : 'a > as 'b
val of_object : < clone : 'b ; count : int ; next : 'a > as 'b -> 'a t
val enum : 'a t -> 'a t
val of_enum : 'a t -> 'a t
val count : 'a t -> int
val fast_count : 'a t -> bool
val hard_count : 'a t -> int
val range : ?until:int -> int -> int t
val dup : 'a t -> 'a t * 'a t
val combine : ('a t * 'b t) -> ('a * 'b) t
val uncombine : ('a * 'b) t -> 'a t * 'b t
val merge : ('a -> 'a -> bool) -> 'a t -> 'a t -> 'a t
val interleave : 'a t array -> 'a t
val uniq : 'a t -> 'a t
val uniqq : 'a t -> 'a t
val uniq_by : ('a -> 'a -> bool) -> 'a t -> 'a t
val switch : ('a -> bool) -> 'a t -> 'a t * 'a t
val partition : ('a -> bool) -> 'a t -> 'a t * 'a t
val arg_min : ('a -> 'b) -> 'a t -> 'a
val arg_max : ('a -> 'b) -> 'a t -> 'a
val while_do : ('a -> bool) -> ('a t -> 'a t) -> 'a t -> 'a t
module Infix : sig ... end
val (--) : int -> int -> int t
val (--^) : int -> int -> int t
val (--.) : (float * float) -> float -> float t
val (---) : int -> int -> int t
val (--~) : char -> char -> char t
val (//) : 'a t -> ('a -> bool) -> 'a t
val (/@) : 'a t -> ('a -> 'b) -> 'b t
val (@/) : ('a -> 'b) -> 'a t -> 'b t
val (//@) : 'a t -> ('a -> 'b option) -> 'b t
val (@//) : ('a -> 'b option) -> 'a t -> 'b t
module WithMonad (Mon : BatInterfaces.Monad) : sig ... end
module Monad : sig ... end
val print : ?first:string -> ?last:string -> ?sep:string -> ('a BatInnerIO.output -> 'b -> unit) -> 'a BatInnerIO.output -> 'b t -> unit
val print_at_most : ?first:string -> ?last:string -> ?sep:string -> limit:int -> ('a BatInnerIO.output -> 'b -> unit) -> 'a BatInnerIO.output -> 'b t -> unit
val compare : ('a -> 'a -> int) -> 'a t -> 'a t -> int
val ord : ('a -> 'a -> BatOrd.order) -> 'a t -> 'a t -> BatOrd.order
val equal : ('a -> 'a -> bool) -> 'a t -> 'a t -> bool
module Exceptionless : sig ... end
val iapp : 'a t -> 'a t -> 'a t
val icons : 'a -> 'a t -> 'a t
val ising : 'a -> 'a t
val lapp : (unit -> 'a t) -> 'a t -> 'a t
val lcons : (unit -> 'a) -> 'a t -> 'a t
val lsing : (unit -> 'a) -> 'a t
val slazy : (unit -> 'a t) -> 'a t
val find : ('a -> bool) -> 'a BatEnum.t -> 'a option
module Labels : sig ... end
OCaml

Innovation. Community. Security.