package camlpdf

  1. Overview
  2. Docs
val is_delimiter : char -> bool
type saved_encryption = {
  1. from_get_encryption_values : Pdfcryptprimitives.encryption * string * string * int32 * string * string option * string option;
  2. encrypt_metadata : bool;
  3. perms : string;
}
type deferred_encryption = {
  1. crypt_type : Pdfcryptprimitives.encryption;
  2. file_encryption_key : string option;
  3. obj : int;
  4. gen : int;
  5. key : int array;
  6. keylength : int;
  7. r : int;
}
val print_deferred_encryption : deferred_encryption -> unit
type toget_crypt =
  1. | NoChange
  2. | ToDecrypt of deferred_encryption
type toget = {
  1. input : Pdfio.input;
  2. position : int;
  3. length : int;
  4. crypt : toget_crypt;
}
val toget : ?crypt:toget_crypt -> Pdfio.input -> int -> int -> toget
val length_of_toget : toget -> int
val position_of_toget : toget -> int
val input_of_toget : toget -> Pdfio.input
type stream =
  1. | Got of Pdfio.bytes
  2. | ToGet of toget
type pdfobject =
  1. | Null
  2. | Boolean of bool
  3. | Integer of int
  4. | Real of float
  5. | String of string
  6. | Name of string
  7. | Array of pdfobject list
  8. | Dictionary of (string * pdfobject) list
  9. | Stream of (pdfobject * stream) ref
  10. | Indirect of int
val string_of_pdf : (pdfobject -> string) ref
type objectdata =
  1. | Parsed of pdfobject
  2. | ParsedAlreadyDecrypted of pdfobject
  3. | ToParse
  4. | ToParseFromObjectStream of (int, int list) Hashtbl.t * int * int * int -> int list -> (int * (objectdata ref * int)) list
type pdfobjmap_key = int
type pdfobjmap = (int, objectdata ref * int) Hashtbl.t
val pdfobjmap_empty : unit -> pdfobjmap
val pdfobjmap_find : 'a -> ('b, 'c) Hashtbl.t -> 'd
val pdfobjmap_add : 'a -> 'b -> ('c, 'd) Hashtbl.t -> ('c, 'd) Hashtbl.t
val pdfobjmap_bindings_inorder : ('a, 'b) Hashtbl.t -> ('c * 'd) list
val pdfobjmap_iter_inorder : ('a -> 'b -> unit) -> ('c, 'd) Hashtbl.t -> unit
val pdfobjmap_bindings : ('a, 'b) Hashtbl.t -> ('c * 'd) list
val pdfobjmap_iter : ('a -> 'b -> unit) -> ('a, 'b) Hashtbl.t -> unit
val pdfobjmap_remove : 'a -> ('b, 'c) Hashtbl.t -> ('b, 'c) Hashtbl.t
type pdfobjects = {
  1. mutable maxobjnum : int;
  2. mutable parse : (pdfobjmap_key -> pdfobject) option;
  3. mutable pdfobjects : pdfobjmap;
  4. mutable object_stream_ids : (int, int) Hashtbl.t;
}
type t = {
  1. mutable major : int;
  2. mutable minor : int;
  3. mutable root : int;
  4. mutable objects : pdfobjects;
  5. mutable trailerdict : pdfobject;
  6. mutable was_linearized : bool;
  7. mutable saved_encryption : saved_encryption option;
}
val empty : unit -> t
exception PDFError of string
val input_pdferror : Pdfio.input -> string -> string
val is_whitespace : char -> bool
val is_not_whitespace : char -> bool
val process_deferred_cryption : toget_crypt -> Pdfio.bytes -> Pdfio.bytes
val remove_string_compare : string -> (string * 'a) list -> (string * 'a) list
val remove_dict_entry : pdfobject -> string -> pdfobject
val replace_dict_entry : pdfobject -> string -> pdfobject -> pdfobject
val add_dict_entry : pdfobject -> string -> pdfobject -> pdfobject
val getstream : pdfobject -> unit
val recurse_array : (pdfobject -> pdfobject) -> pdfobject list -> pdfobject
val recurse_dict_inner : ('a -> 'b) -> ('c * 'd) list -> ('e * 'f) list -> ('c * 'd) list
val recurse_dict : (pdfobject -> pdfobject) -> (string * pdfobject) list -> pdfobject
val getnum : pdfobject -> float
val parse_rectangle : pdfobject -> float * float * float * float
val change_obj : t -> int -> pdfobject -> unit
val parse_lazy : t -> pdfobjmap_key -> pdfobject
val removeobj : t -> int -> unit
val lookup_obj : t -> pdfobjmap_key -> pdfobject
val parse_delayed_object_stream : (pdfobjmap_key, int list) Hashtbl.t -> pdfobjmap_key -> int -> t -> (int -> int list -> (pdfobjmap_key * (objectdata ref * int)) list) -> pdfobject
val resolve_all_delayed_object_streams : t -> unit
val catalog_of_pdf : t -> pdfobject
val direct : t -> pdfobject -> pdfobject
val iter_stream : (pdfobject -> unit) -> t -> unit
val lookup_string_compare : string -> (string * 'a) list -> 'b option
val lookup_direct : t -> string -> pdfobject -> pdfobject option
val indirect_number : t -> string -> pdfobject -> int option
val lookup_direct_orelse : t -> string -> string -> pdfobject -> pdfobject option
val lookup_exception : exn -> t -> string -> pdfobject -> pdfobject
val lookup_fail : string -> t -> string -> pdfobject -> pdfobject
val parse_matrix : t -> string -> pdfobject -> Pdftransform.transform_matrix
val objiter : (pdfobjmap_key -> pdfobject -> unit) -> t -> unit
val objselfmap : (pdfobject -> pdfobject) -> t -> unit
val objiter_inorder : (pdfobjmap_key -> pdfobject -> unit) -> t -> unit
val objiter_gen : (pdfobjmap_key -> int -> pdfobject -> unit) -> t -> unit
val objnumbers : t -> pdfobjmap_key list
val objcard : t -> int
val list_of_objs : t -> (pdfobjmap_key * objectdata) list
val addobj_given_num : t -> (int * pdfobject) -> unit
val addobj : t -> pdfobject -> int
val objects_of_list : (pdfobjmap_key -> pdfobject) option -> (int * (objectdata ref * int)) list -> pdfobjects
val page_reference_numbers_inner : t -> pdfobject -> int -> int list
val page_reference_numbers : t -> int list
val renumber_object_parsed : t -> (int, int) Hashtbl.t -> pdfobject -> pdfobject
val renumber_object : t -> (int, int) Hashtbl.t -> pdfobjmap_key -> objectdata -> pdfobject
val changes : t -> (pdfobjmap_key, int) Hashtbl.t
val renumber : (pdfobjmap_key, int) Hashtbl.t -> t -> t
val renumber_pdfs : t list -> t list
val allfalse : bool list -> bool
val containing : ('a * pdfobject) list -> ('b * pdfobject) -> bool
val tocontinue : 'a list -> ('b * pdfobject) list -> ('b * pdfobject) list -> bool
val refset_empty : unit -> ('a, 'b) Hashtbl.t
val refset_add : 'a -> ('b, unit) Hashtbl.t -> ('b, unit) Hashtbl.t
val refset_mem : 'a -> ('b, 'c) Hashtbl.t -> bool
val refset_elts : ('a, 'b) Hashtbl.t -> 'c list
val referenced_pdfobj : string list -> (string * pdfobject) list -> t -> (int, unit) Hashtbl.t ref -> pdfobjmap_key -> pdfobject -> unit
val referenced : string list -> (string * pdfobject) list -> t -> (int, unit) Hashtbl.t ref -> pdfobjmap_key -> objectdata -> unit
val nullify_deleted_page_references : t -> unit
val remove_unreferenced : t -> unit
val objects_referenced : string list -> (string * pdfobject) list -> t -> pdfobject -> int list
val bigarray_of_stream : pdfobject -> Pdfio.bytes
val unique_key : string -> pdfobject -> string
val generate_id : 'a -> string -> (unit -> float) -> pdfobject
val find_indirect : string -> pdfobject -> int option
val nametree_lookup_kids : t -> pdfobject -> pdfobject -> pdfobject option
val array_lookup : pdfobject -> pdfobject -> pdfobject option
val nametree_lookup : t -> pdfobject -> pdfobject -> pdfobject option
val contents_of_nametree : t -> pdfobject -> (pdfobject * pdfobject) list
val deep_copy_pdfobjects : t -> (int, objectdata ref * int) Hashtbl.t -> pdfobjmap
val deep_copy : t -> t
val change_id : t -> string -> unit