package vhd-format

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type feature =
  1. | Feature_no_features_enabled
  2. | Feature_temporary
  3. | Feature_reserved
type disk_type =
  1. | DT_None
  2. | DT_Reserved of int
  3. | DT_Fixed_hard_disk
  4. | DT_Dynamic_hard_disk
  5. | DT_Differencing_hard_disk
type geometry = {
  1. g_cylinders : int;
  2. g_heads : int;
  3. g_sectors : int;
}
type parent_locator = {
  1. platform_code : int32;
  2. platform_data_space : int32;
  3. platform_data_space_original : int32;
  4. platform_data_length : int32;
  5. mutable platform_data_offset : int64;
  6. platform_data : string;
}
type vhd_header = {
  1. h_data_offset : int64;
  2. mutable h_table_offset : int64;
  3. h_header_version : int32;
  4. mutable h_max_table_entries : int32;
  5. h_block_size : int32;
  6. h_checksum : int32;
  7. h_parent_unique_id : string;
  8. h_parent_time_stamp : int32;
  9. h_parent_unicode_name : int array;
  10. h_parent_locators : parent_locator array;
}
type vhd = {
  1. filename : string;
  2. mmap : Lwt_bytes.t;
  3. header : vhd_header;
  4. footer : vhd_footer;
  5. parent : vhd option;
  6. bat : int32 array;
}
val null_locator : parent_locator
val platform_code_wi2r : int32
val platform_code_wi2k : int32
val platform_code_w2ru : int32
val platform_code_w2ku : int32
val platform_code_mac : int32
val platform_code_macx : int32
val sector_size : int
val sector_sizeL : int64
val block_size : int32
val unusedl : int32
val unusedL : int64
val header_version : int32
val creator_application : string
val creator_version : int32
val y2k : float
val really_read : Lwt_bytes.t -> int64 -> int64 -> bytes Lwt.t
val really_write : Lwt_bytes.t -> int64 -> string -> unit Lwt.t
val utf16_to_string : int array -> string
val get_chs : int -> int * int * int
val get_vhd_time : float -> int32
val get_now : unit -> int32
val get_parent_modification_time : string -> int32
val utf16_of_utf8 : string -> int array
val unmarshal_uint8 : (string * int) -> int * (string * int)
val unmarshal_uint16 : ?bigendian:bool -> (string * int) -> int * (string * int)
val unmarshal_uint32 : ?bigendian:bool -> (string * int) -> int32 * (string * int)
val unmarshal_uint64 : ?bigendian:bool -> (string * int) -> int64 * (string * int)
val unmarshal_string : int -> (string * int) -> string * (string * int)
val unmarshal_utf16_string : int -> (string * int) -> int array * (string * int)
val marshal_int8 : int -> string
val marshal_int16 : ?bigendian:bool -> int -> string
val marshal_int32 : ?bigendian:bool -> int32 -> string
val marshal_int64 : ?bigendian:bool -> int64 -> string
val marshal_utf16 : int array -> string
val pad_string_to : string -> int -> string
val get_block_sizes : vhd -> int32 * int32 * int32
val unmarshal_geometry : (string * int) -> geometry * (string * int)
val unmarshal_parent_locator : Lwt_bytes.t -> (string * int) -> (parent_locator * (string * int)) Lwt.t
val unmarshal_n : int -> 'a -> ('a -> ('b * 'a) Lwt.t) -> ('b list * 'a) Lwt.t
val unmarshal_parent_locators : Lwt_bytes.t -> (string * int) -> (parent_locator array * (string * int)) Lwt.t
val parse_bitfield : int64 -> int list
val uuidarr_to_string : int array -> string
val read_header : Lwt_bytes.t -> int64 -> vhd_header Lwt.t
val read_bat : Lwt_bytes.t -> 'a -> vhd_header -> int32 array Lwt.t
val read_bitmap : vhd -> int -> int array Lwt.t
val get_parent_filename : vhd_header -> string
val load_vhd : string -> vhd Lwt.t
val marshal_features : feature list -> string
val marshal_geometry : geometry -> string
val marshal_disk_type : disk_type -> string
val string_to_uuidarr : string -> int array
val marshal_uuid : string -> string
val marshal_parent_locator_entry : parent_locator -> string
val generic_calc_checksum : string -> int32
val marshal_header_no_checksum : vhd_header -> string
val calc_checksum_header : vhd_header -> int32 * string
val marshal_header : vhd_header -> string
val write_locator : Lwt_bytes.t -> parent_locator -> unit Lwt.t
val write_locators : Lwt_bytes.t -> vhd_header -> unit Lwt.t
val write_bat : Lwt_bytes.t -> vhd -> unit Lwt.t
val dump_sector : string -> unit
val feature_to_string : feature -> string
val disk_type_to_string : disk_type -> string
val parent_locator_to_string : parent_locator -> string
val dump_header : vhd_header -> unit
val dump_bat : int32 array -> unit
val dump_vhd : vhd -> unit
val get_offset_info_of_sector : vhd -> int64 -> int * int64 * int * int * int * int * int64 * int64
val get_sector_pos : vhd -> int64 -> (Lwt_bytes.t * int64) option Lwt.t
exception EmptyVHD
val get_top_unused_offset : vhd -> int64
val write_vhd : vhd -> unit Lwt.t
val write_clean_block : vhd -> int -> unit Lwt.t
val write_sector : vhd -> int64 -> string -> unit Lwt.t
val rewrite_block : 'a -> 'b -> 'c -> unit
type block_marker =
  1. | Start of string * int64
  2. | End of string * int64
val check_overlapping_blocks : vhd -> unit
val create_new_dynamic : string -> int64 -> string -> ?sparse:bool -> ?table_offset:int64 -> ?block_size:int32 -> ?data_offset:int64 -> ?saved_state:bool -> ?features:feature list -> unit -> vhd Lwt.t
val create_new_difference : string -> string -> string -> ?features:feature list -> ?data_offset:int64 -> ?saved_state:bool -> ?table_offset:int64 -> unit -> vhd Lwt.t
val make_uuid : unit -> string
val round_up_to_2mb_block : int64 -> int64
OCaml

Innovation. Community. Security.