summaryrefslogtreecommitdiffstats
path: root/ocaml/guestfs.mli
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2009-04-07 16:52:25 +0100
committerRichard Jones <rjones@redhat.com>2009-04-07 16:52:25 +0100
commit4144e2106cc70ad8f1e081b57da09f9c1e276812 (patch)
tree55022dd599e4d1583b7c93de338d7c85c15a0fe7 /ocaml/guestfs.mli
parent21ba59ce3cbc594ce9c7aeecd4dadb8430e4042d (diff)
downloadlibguestfs-4144e2106cc70ad8f1e081b57da09f9c1e276812.tar.gz
libguestfs-4144e2106cc70ad8f1e081b57da09f9c1e276812.tar.xz
libguestfs-4144e2106cc70ad8f1e081b57da09f9c1e276812.zip
Outline OCaml bindings.
Diffstat (limited to 'ocaml/guestfs.mli')
-rw-r--r--ocaml/guestfs.mli153
1 files changed, 153 insertions, 0 deletions
diff --git a/ocaml/guestfs.mli b/ocaml/guestfs.mli
new file mode 100644
index 00000000..ba750368
--- /dev/null
+++ b/ocaml/guestfs.mli
@@ -0,0 +1,153 @@
+(* libguestfs generated file
+ * WARNING: THIS FILE IS GENERATED BY 'src/generator.ml'.
+ * ANY CHANGES YOU MAKE TO THIS FILE WILL BE LOST.
+ *
+ * Copyright (C) 2009 Red Hat Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *)
+
+(** For API documentation you should refer to the C API
+ in the guestfs(3) manual page. The OCaml API uses almost
+ exactly the same calls. *)
+
+type t
+(** A [guestfs_h] handle. *)
+
+exception Error of string
+(** This exception is raised when there is an error. *)
+
+val create : unit -> t
+
+val close : t -> unit
+(** Handles are closed by the garbage collector when they become
+ unreferenced, but callers can also call this in order to
+ provide predictable cleanup. *)
+
+val launch : t -> unit
+val wait_ready : t -> unit
+val kill_subprocess : t -> unit
+
+val add_drive : t -> string -> unit
+val add_cdrom : t -> string -> unit
+val config : t -> string -> string option -> unit
+
+val set_path : t -> string option -> unit
+val get_path : t -> string
+val set_autosync : t -> bool -> unit
+val get_autosync : t -> bool
+val set_verbose : t -> bool -> unit
+val get_verbose : t -> bool
+
+type lvm_pv = {
+ pv_name : string;
+ pv_uuid : string;
+ pv_fmt : string;
+ pv_size : int64;
+ dev_size : int64;
+ pv_free : int64;
+ pv_used : int64;
+ pv_attr : string;
+ pv_pe_count : int64;
+ pv_pe_alloc_count : int64;
+ pv_tags : string;
+ pe_start : int64;
+ pv_mda_count : int64;
+ pv_mda_free : int64;
+}
+
+type lvm_vg = {
+ vg_name : string;
+ vg_uuid : string;
+ vg_fmt : string;
+ vg_attr : string;
+ vg_size : int64;
+ vg_free : int64;
+ vg_sysid : string;
+ vg_extent_size : int64;
+ vg_extent_count : int64;
+ vg_free_count : int64;
+ max_lv : int64;
+ max_pv : int64;
+ pv_count : int64;
+ lv_count : int64;
+ snap_count : int64;
+ vg_seqno : int64;
+ vg_tags : string;
+ vg_mda_count : int64;
+ vg_mda_free : int64;
+}
+
+type lvm_lv = {
+ lv_name : string;
+ lv_uuid : string;
+ lv_attr : string;
+ lv_major : int64;
+ lv_minor : int64;
+ lv_kernel_major : int64;
+ lv_kernel_minor : int64;
+ lv_size : int64;
+ seg_count : int64;
+ origin : string;
+ snap_percent : float option;
+ copy_percent : float option;
+ move_pv : string;
+ lv_tags : string;
+ mirror_log : string;
+ modules : string;
+}
+
+val cat : t -> string -> string
+(** list the contents of a file *)
+
+val list_devices : t -> string list
+(** list the block devices *)
+
+val list_partitions : t -> string list
+(** list the partitions *)
+
+val ll : t -> string -> string
+(** list the files in a directory (long format) *)
+
+val ls : t -> string -> string list
+(** list the files in a directory *)
+
+val lvs : t -> string list
+(** list the LVM logical volumes (LVs) *)
+
+val lvs_full : t -> lvm_lv list
+(** list the LVM logical volumes (LVs) *)
+
+val mount : t -> string -> string -> unit
+(** mount a guest disk at a position in the filesystem *)
+
+val pvs : t -> string list
+(** list the LVM physical volumes (PVs) *)
+
+val pvs_full : t -> lvm_pv list
+(** list the LVM physical volumes (PVs) *)
+
+val sync : t -> unit
+(** sync disks, writes are flushed through to the disk image *)
+
+val touch : t -> string -> unit
+(** update file timestamps or create a new file *)
+
+val vgs : t -> string list
+(** list the LVM volume groups (VGs) *)
+
+val vgs_full : t -> lvm_vg list
+(** list the LVM volume groups (VGs) *)
+