package decompress

  1. Overview
  2. Docs
module Heap : sig ... end
module Huffman : sig ... end
val reverse_bits : int -> int
module Lookup : sig ... end
type ('i, 'o) t = {
  1. last : bool;
  2. hold : int;
  3. bits : int;
  4. o_off : int;
  5. o_pos : int;
  6. o_len : int;
  7. i_off : int;
  8. i_pos : int;
  9. i_len : int;
  10. write : int;
  11. state : ('i, 'o) state;
  12. window : 'o Window.t;
  13. wbits : int;
  14. wi : 'i B.t;
  15. wo : 'o B.t;
}
and ('i, 'o) k = (Safe.ro, 'i) Safe.t -> (Safe.wo, 'o) Safe.t -> ('i, 'o) t -> ('i, 'o) res
and ('i, 'o) state =
  1. | Last
  2. | Block
  3. | Flat of ('i, 'o) k
  4. | Fixed
  5. | Dictionary of ('i, 'o) k
  6. | Inffast of Lookup.t * Lookup.t * code
  7. | Inflate of ('i, 'o) k
  8. | Switch
  9. | Finish of int
  10. | Exception of error
and ('i, 'o) res =
  1. | Cont of ('i, 'o) t
  2. | Wait of ('i, 'o) t
  3. | Flush of ('i, 'o) t
  4. | Ok of ('i, 'o) t
  5. | Error of ('i, 'o) t * error
and code =
  1. | Length
  2. | ExtLength of int
  3. | Dist of int
  4. | ExtDist of int * int
  5. | Write of int * int
val pp_error : Format.formatter -> error_rfc1951_inflate -> unit
val pp_code : Format.formatter -> code -> unit
val pp_state : Format.formatter -> ('a, 'b) state -> unit
val pp : Format.formatter -> ('a, 'b) t -> unit
val error : ('a, 'b) t -> error -> ('a, 'b) res
val ok : ('a, 'b) t -> int -> ('a, 'b) res
val get_byte : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> (int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
val put_byte : ctor: (('a -> ([< `Rd | `Wr Wr ] as 'b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) -> ('d, 'c) state) -> int -> ('a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) -> 'a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res
val fill_byte : ctor: (('a -> ([< `Rd | `Wr Wr ] as 'b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) -> ('d, 'c) state) -> int -> int -> ('a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) -> 'a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res
val peek_bits : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> int -> (('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
val drop_bits : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> int -> (('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
val get_bits : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> int -> (int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
val get_with_holding : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> (int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
val get_int16 : ctor: ((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('b, 'd) state) -> (int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res
module KLast : sig ... end
module KBlock : sig ... end
module KDictionary : sig ... end
module KFlat : sig ... end
module KInflate : sig ... end
module Dictionary : sig ... end
val fixed : 'a -> 'b -> ('c, 'd) t -> ('c, 'd) res
val dictionary : (Safe.ro, 'a) Safe.t -> (Safe.wo, 'b) Safe.t -> ('a, 'b) t -> ('a, 'b) res
val switch : 'a -> 'b -> ('c, 'd) t -> ('c, 'd) res
val flat : (Safe.ro, 'a) Safe.t -> (Safe.wo, 'a) Safe.t -> ('a, 'a) t -> ('a, 'a) res
val inflate : Lookup.t -> Lookup.t -> (Safe.ro, 'a) Safe.t -> (Safe.wo, 'b) Safe.t -> ('a, 'b) t -> ('a, 'b) res
exception End
exception Exn_invalid_distance of int * int
val inffast : ([< `Rd | `Wr Rd ], 'a) Safe.t -> ([< `Rd | `Wr Wr ], 'b) Safe.t -> ('a, 'b) t -> Lookup.t -> Lookup.t -> code -> ('a, 'b) res
val block : ([< `Rd | `Wr Rd ], 'a) Safe.t -> 'b -> ('a, 'a) t -> ('a, 'a) res
val last : ([< `Rd | `Wr Rd ], 'a) Safe.t -> 'b -> ('a, 'c) t -> ('a, 'c) res
val eval0 : (Safe.ro, 'a) Safe.t -> (Safe.wo, 'a) Safe.t -> ('a, 'a) t -> ('a, 'a) res
val eval : 'a -> 'a -> ('a, 'a) t -> [> `Await of ('a, 'a) t | `End of ('a, 'a) t | `Error of ('a, 'a) t * error | `Flush of ('a, 'a) t ]
val default : witness:'a B.t -> ?wbits:int -> 'a Window.t -> ('a, 'a) t
val refill : int -> int -> ('a, 'b) t -> ('a, 'b) t
val flush : int -> int -> ('a, 'b) t -> ('a, 'b) t
val used_in : ('a, 'b) t -> int
val used_out : ('a, 'b) t -> int
val write : ('a, 'b) t -> int
val bits_remaining : ('a, 'b) t -> int
include sig ... end
val to_result : 'a -> 'a -> ('a -> int) -> ('a -> int -> int) -> ('a, 'a) t -> (('a, 'a) t, error) Pervasives.result
val bytes : 'a -> 'a -> ('a -> int) -> ('a -> int -> int) -> ('a, 'a) t -> (('a, 'a) t, error) Pervasives.result
val bigstring : 'a -> 'a -> ('a -> int) -> ('a -> int -> int) -> ('a, 'a) t -> (('a, 'a) t, error) Pervasives.result
OCaml

Innovation. Community. Security.