Module Reader0.Internal

module Internal: sig .. end

module State: sig .. end
module Open_flags: Reader0.Unix.Open_flags
type open_flags = (Open_flags.t, exn) Core.Std.Result.t 
val sexp_of_open_flags : (Open_flags.t, Core_kernel.Exn.t) Core.Std.Result.t ->
Sexplib.Sexp.t
type t = {
   fd : Fd.t;
   id : Reader0.Id.t;
   mutable buf : Core.Std.Bigstring.t Core.Std.sexp_opaque;
   mutable close_may_destroy_buf : [ `Not_ever | `Not_now | `Yes ];
   mutable pos : int;
   mutable available : int;
   mutable bin_prot_len_buf : Core.Std.Bigstring.t Core.Std.sexp_opaque;
   mutable bin_prot_buf : Core.Std.Bigstring.t Core.Std.sexp_opaque;
   mutable state : State.t;
   close_finished : unit Import.Ivar.t;
   mutable last_read_time : Core.Std.Time.t;
   open_flags : open_flags Import.Deferred.t;
}
val sexp_of_t : t -> Sexplib.Sexp.t
val open_flags : t -> open_flags Import.Deferred.t
val last_read_time : t -> Core.Std.Time.t
val set_last_read_time : t -> Core.Std.Time.t -> unit
val close_finished : t -> unit Import.Ivar.Deferred.t
val state : t -> State.t
val set_state : t -> State.t -> unit
val bin_prot_buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque
val set_bin_prot_buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque -> unit
val bin_prot_len_buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque
val set_bin_prot_len_buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque -> unit
val available : t -> int
val set_available : t -> int -> unit
val pos : t -> int
val set_pos : t -> int -> unit
val close_may_destroy_buf : t -> [ `Not_ever | `Not_now | `Yes ]
val set_close_may_destroy_buf : t -> [ `Not_ever | `Not_now | `Yes ] -> unit
val buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque
val set_buf : t -> Core.Std.Bigstring.t Core.Std.sexp_opaque -> unit
val id : t -> Reader0.Id.t
val fd : t -> Fd.t
module Fields: sig .. end
val io_stats : Io_stats.t
val invariant : t -> unit
val create : ?buf_len:int -> Fd.t -> t
val of_in_channel : Core.Std.In_channel.t -> Fd.Kind.t -> t
val open_file : ?close_on_exec:bool ->
?buf_len:int -> string -> t Async_core.Deferred.t
val stdin : t lazy_t
val close_finished : t -> unit Import.Ivar.Deferred.t
val is_closed : t -> bool
val empty_buf : Core.Std.Bigstring.t
val destroy : t -> unit
val close : t -> unit Import.Ivar.Deferred.t
val with_close : t ->
f:(unit -> 'a Async_core.Deferred.t) -> 'a Async_core.Deferred.t
val with_reader_exclusive : t ->
(unit -> 'a Async_core.Deferred.t) -> 'a Async_core.Deferred.t
val with_file : ?buf_len:int ->
?exclusive:bool ->
string ->
f:(t -> 'a Async_core.Deferred.t) ->
'a Async_core.Deferred.t
val get_data : t -> [ `Eof | `Ok ] Import.Deferred.t
val with_nonempty_buffer : t -> ([ `Eof | `Ok ] -> 'a) -> 'a Import.Deferred.t
val with_nonempty_buffer' : ?force_refill:bool -> t -> ([ `Eof | `Ok ] -> unit) -> unit
val consume : t -> int -> unit
type 'a read_one_chunk_at_a_time_result = [ `Eof | `Eof_with_unconsumed_data of string | `Stopped of 'a ] 
val sexp_of_read_one_chunk_at_a_time_result : 'a.
('a -> Sexplib.Sexp.t) ->
'a read_one_chunk_at_a_time_result -> Sexplib.Sexp.t
type consumed = [ `Consumed of int * [ `Need of int | `Need_unknown ] ] 
val sexp_of_consumed : [< `Consumed of int * [< `Need of int | `Need_unknown ] ] -> Sexplib.Sexp.t
val read_one_chunk_at_a_time : t ->
handle_chunk:(Core.Std.Bigstring.t Core.Std.sexp_opaque ->
pos:int ->
len:int ->
[< `Consumed of
int * [< `Need of int | `Need_unknown ] &
int * [< `Need of int | `Need_unknown ]
| `Continue
| `Stop of 'a
| `Stop_consumed of 'a * int ]
Import.Deferred.t) ->
[> `Eof | `Eof_with_unconsumed_data of string | `Stopped of 'a ]
Import.Deferred.t
module Read: 
functor (S : Core.Std.Substring_intf.S) ->
functor (Name : sig
val name : string
end) -> sig .. end
module Read_substring: Read(Core.Std.Substring)(sig
val name : string
end)
val read_substring : t ->
Core.Std.Substring.t -> [> `Eof | `Ok of Core.Std.Int.t ] Import.Deferred.t
val really_read_substring : t ->
Core.Std.Substring.t -> [> `Eof of int | `Ok ] Import.Deferred.t
module Read_bigsubstring: Read(Core.Std.Bigsubstring)(sig
val name : string
end)
val read_bigsubstring : t ->
Core.Std.Bigsubstring.t ->
[> `Eof | `Ok of Core.Std.Int.t ] Import.Deferred.t
val really_read_bigsubstring : t ->
Core.Std.Bigsubstring.t -> [> `Eof of int | `Ok ] Import.Deferred.t
val really_read_bigstring : t ->
Core_kernel.Bigstring.t -> [> `Eof of int | `Ok ] Import.Deferred.t
val read : t ->
?pos:int ->
?len:int ->
Core.Std.Substring.base ->
[> `Eof | `Ok of Core.Std.Int.t ] Import.Deferred.t
val really_read : t ->
?pos:int ->
?len:int ->
Core.Std.Substring.base -> [> `Eof of int | `Ok ] Import.Deferred.t
val read_char : t -> [> `Eof | `Ok of char ] Import.Deferred.t
val first_char : t ->
[< `Char of char | `Pred of char -> bool ] -> int option Core.Std.Or_error.t
val read_until_gen : t ->
[< `Char of char | `Pred of char -> bool ] ->
keep_delim:bool ->
max:int option ->
(([> `Eof
| `Eof_without_delim of string
| `Max_exceeded of string
| `Ok of string ],
Core_kernel.Error.t)
Core.Std._result -> unit) ->
unit
val read_until : t ->
[< `Char of char | `Pred of char -> bool ] ->
keep_delim:bool ->
(([> `Eof | `Eof_without_delim of string | `Ok of string ],
Core_kernel.Error.t)
Core.Std._result -> unit) ->
unit
val line_delimiter_pred : [> `Char of char ]
val read_line_gen : t ->
([> `Eof | `Eof_without_delim of string | `Ok of Core.Std.String.t ] -> unit) ->
unit
val read_line : t -> [> `Eof | `Ok of Core.Std.String.t ] Import.Deferred.t
val really_read_line : wait_time:Core.Std.Time.Span.t ->
t -> Core.Std.String.t option Import.Deferred.t
val space : Core.Std.Bigstring.t
val gen_read_sexp : ?parse_pos:Core.Std.Sexp.Parse_pos.t ->
t ->
(?parse_pos:Core.Std.Sexp.Parse_pos.t ->
?len:int ->
Core.Std.Bigstring.t ->
(Core.Std.Bigstring.t, 'a) Core.Std.Sexp.parse_result) ->
(([> `Eof | `Ok of 'a * Core.Std.Sexp.Parse_pos.t ], Core_kernel.Error.t)
Core.Std._result -> unit) ->
unit
type 'a read = ?parse_pos:Core.Std.Sexp.Parse_pos.t -> 'a 
val gen_read_sexps : ?parse_pos:Core.Std.Sexp.Parse_pos.t ->
t ->
(?parse_pos:Core.Std.Sexp.Parse_pos.t ->
?len:int ->
Core.Std.Bigstring.t ->
(Core.Std.Bigstring.t, 'a) Core.Std.Sexp.parse_result) ->
'a Import.Pipe.Reader.t
val read_sexps : ?parse_pos:Core.Std.Sexp.Parse_pos.t ->
t -> Core.Std.Sexp.t Import.Pipe.Reader.t
val read_annotated_sexps : ?parse_pos:Core.Std.Sexp.Parse_pos.t ->
t -> Core.Std.Sexp.Annotated.t Import.Pipe.Reader.t
val read_bin_prot : ?max_len:Core.Std.Int.t ->
t ->
'a Reader0.Type_class.reader ->
([> `Eof | `Ok of 'a ] Core.Std.Or_error.t -> unit) -> unit
val read_marshal_raw : t ->
[> `Eof | `Ok of Core.Std.String.t ] Async_core.Deferred.t
val read_marshal : t -> [> `Eof | `Ok of 'a ] Async_core.Deferred.t
val read_all : t ->
(t -> [< `Eof | `Ok of 'a ] Async_core.Deferred.t) ->
'a Import.Pipe.Reader.t
val lines : t -> Core.Std.String.t Import.Pipe.Reader.t
val contents : t -> string Async_core.Deferred.t
val recv : t -> [> `Eof | `Ok of Core.Std.String.t ] Import.Deferred.t
val transfer : t ->
(string, Import.Pipe.Writer.phantom) Import.Pipe.t -> unit Import.Deferred.t