sig
type t = string
exception Malformed_code
val validate : BatUTF8.t -> unit
val get : BatUTF8.t -> int -> BatUChar.t
val init : int -> (int -> BatUChar.t) -> BatUTF8.t
val length : BatUTF8.t -> int
type index = int
val nth : BatUTF8.t -> int -> BatUTF8.index
val first : BatUTF8.t -> BatUTF8.index
val last : BatUTF8.t -> BatUTF8.index
val look : BatUTF8.t -> BatUTF8.index -> BatUChar.t
val out_of_range : BatUTF8.t -> BatUTF8.index -> bool
val compare_index : BatUTF8.t -> BatUTF8.index -> BatUTF8.index -> int
val next : BatUTF8.t -> BatUTF8.index -> BatUTF8.index
val prev : BatUTF8.t -> BatUTF8.index -> BatUTF8.index
val move : BatUTF8.t -> BatUTF8.index -> int -> BatUTF8.index
val iter : (BatUChar.t -> unit) -> BatUTF8.t -> unit
val compare : BatUTF8.t -> BatUTF8.t -> int
module Buf :
sig
type buf = Stdlib.Buffer.t
val create : int -> BatUTF8.Buf.buf
val contents : BatUTF8.Buf.buf -> BatUTF8.t
val clear : BatUTF8.Buf.buf -> unit
val reset : BatUTF8.Buf.buf -> unit
val add_char : BatUTF8.Buf.buf -> BatUChar.t -> unit
val add_string : BatUTF8.Buf.buf -> BatUTF8.t -> unit
val add_buffer : BatUTF8.Buf.buf -> BatUTF8.Buf.buf -> unit
end
val make : int -> BatUChar.t -> BatUTF8.t
val of_string_unsafe : string -> BatUTF8.t
val to_string_unsafe : BatUTF8.t -> string
val of_char : BatUChar.t -> BatUTF8.t
val empty : BatUTF8.t
val sub : BatUTF8.t -> int -> int -> BatUTF8.t
val iteri : (BatUChar.t -> int -> unit) -> BatUTF8.t -> unit
val fold : ('a -> BatUChar.t -> 'a) -> 'a -> BatUTF8.t -> 'a
val enum : BatUTF8.t -> BatUChar.t BatEnum.t
val map : (BatUChar.t -> BatUChar.t) -> BatUTF8.t -> BatUTF8.t
val filter_map :
(BatUChar.t -> BatUChar.t option) -> BatUTF8.t -> BatUTF8.t
val filter : (BatUChar.t -> bool) -> BatUTF8.t -> BatUTF8.t
val rindex : BatUTF8.t -> BatUChar.t -> int
val contains : BatUTF8.t -> BatUChar.t -> bool
val escaped : BatUTF8.t -> BatUTF8.t
val of_latin1 : string -> BatUTF8.t
val length0 : int -> int
module ByteIndex :
sig
type t = string
type b_idx
type char_idx = int
val of_int_unsafe : int -> BatUTF8.ByteIndex.b_idx
val to_int : BatUTF8.ByteIndex.b_idx -> int
val next :
BatUTF8.ByteIndex.t ->
BatUTF8.ByteIndex.b_idx -> BatUTF8.ByteIndex.b_idx
val prev :
BatUTF8.ByteIndex.t ->
BatUTF8.ByteIndex.b_idx -> BatUTF8.ByteIndex.b_idx
val of_char_idx :
BatUTF8.ByteIndex.t ->
BatUTF8.ByteIndex.char_idx -> BatUTF8.ByteIndex.b_idx
val at_end : BatUTF8.ByteIndex.t -> BatUTF8.ByteIndex.b_idx -> bool
val out_of_range :
BatUTF8.ByteIndex.t -> BatUTF8.ByteIndex.b_idx -> bool
val first : BatUTF8.ByteIndex.b_idx
val last : BatUTF8.ByteIndex.t -> BatUTF8.ByteIndex.b_idx
val move :
BatUTF8.ByteIndex.t ->
BatUTF8.ByteIndex.b_idx -> int -> BatUTF8.ByteIndex.b_idx
val look : BatUTF8.ByteIndex.t -> BatUTF8.ByteIndex.b_idx -> BatUChar.t
end
end