package async_kernel

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

All Deferred_queue iteration functions first copy the queue (to a list) and then start calling the user function f. So, if f modifies the queue, that will have no effect on the iteration.

val foldi : 'a Core.Queue.t -> init:'b -> f:(int -> 'b -> 'a -> 'b t) -> 'b t
val fold : 'a Core.Queue.t -> init:'b -> f:('b -> 'a -> 'b t) -> 'b t
val find : 'a Core.Queue.t -> f:('a -> bool t) -> 'a option t
val findi : 'a Core.Queue.t -> f:(int -> 'a -> bool t) -> (int * 'a) option t
val find_map : 'a Core.Queue.t -> f:('a -> 'b option t) -> 'b option t
val find_mapi : 'a Core.Queue.t -> f:(int -> 'a -> 'b option t) -> 'b option t
val exists : 'a Core.Queue.t -> f:('a -> bool t) -> bool t
val existsi : 'a Core.Queue.t -> f:(int -> 'a -> bool t) -> bool t
val for_all : 'a Core.Queue.t -> f:('a -> bool t) -> bool t
val for_alli : 'a Core.Queue.t -> f:(int -> 'a -> bool t) -> bool t
val all : 'a t Core.Queue.t -> 'a Core.Queue.t t
val all_unit : unit t Core.Queue.t -> unit t

Deferred iterators

In the following, the default how is `Sequential

val init : ?how:Monad_sequence.how -> int -> f:(int -> 'a t) -> 'a Core.Queue.t t
val iter : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:('a -> unit t) -> unit t
val iteri : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:(int -> 'a -> unit t) -> unit t
val map : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:('a -> 'b t) -> 'b Core.Queue.t t
val mapi : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:(int -> 'a -> 'b t) -> 'b Core.Queue.t t
val filter : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:('a -> bool t) -> 'a Core.Queue.t t
val filteri : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:(int -> 'a -> bool t) -> 'a Core.Queue.t t
val filter_map : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:('a -> 'b option t) -> 'b Core.Queue.t t
val filter_mapi : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:(int -> 'a -> 'b option t) -> 'b Core.Queue.t t
val concat_map : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:('a -> 'b Core.Queue.t t) -> 'b Core.Queue.t t
val concat_mapi : ?how:Monad_sequence.how -> 'a Core.Queue.t -> f:(int -> 'a -> 'b Core.Queue.t t) -> 'b Core.Queue.t t
OCaml

Innovation. Community. Security.