1 (* virt-manager-like graphical management tool.
2 (C) Copyright 2007 Richard W.M. Jones, Red Hat Inc.
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 Handle connections and the complicated GtkTreeView which
20 displays the connections / domains.
23 (** Get the list of current connections. *)
24 val get_conns : unit -> (int * Libvirt.rw Libvirt.Connect.t) list
26 (** The current/previous state last time repopulate was called. The
27 repopulate function uses this state to determine what has changed
28 (eg. domains added, removed) since last time.
32 type columns = string GTree.column * string GTree.column * string GTree.column * string GTree.column * string GTree.column * int GTree.column
34 (** This function should be called once per second in order to
35 redraw the GtkTreeView.
37 Takes the previous state as a parameter and returns the new state.
39 val repopulate : GTree.view -> GTree.tree_store -> columns -> state -> state
41 (** Create the GtkTreeView. Returns the widget itself, the model,
42 the list of columns, and the initial state.
44 val make_treeview : ?packing:(GObj.widget -> unit) -> unit -> GTree.view * GTree.tree_store * columns * state
46 (** This callback creates the Connect to hypervisor dialog. *)
47 val open_connection : unit -> unit