[gnome-boxes] Update to libgovirt 0.2.0
- From: Christophe Fergeau <teuf src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] Update to libgovirt 0.2.0
- Date: Mon, 12 Aug 2013 13:45:03 +0000 (UTC)
commit 3470926f2b2c506655ff82bf0c73b0fbed0cd8c2
Author: Christophe Fergeau <cfergeau redhat com>
Date: Fri Jul 5 12:14:34 2013 +0200
Update to libgovirt 0.2.0
https://bugzilla.gnome.org/show_bug.cgi?id=703780
configure.ac | 2 +-
src/ovirt-machine.vala | 2 +-
vapi/govirt-1.0.vapi | 54 ++++++++++++++++++++++++++++++++++++++---------
3 files changed, 45 insertions(+), 13 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 7f1271d..3b0fef6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -50,7 +50,7 @@ CLUTTER_MIN_VERSION=1.11.14
GLIB_MIN_VERSION=2.32.0
AC_SUBST(GLIB_MIN_VERSION)
GOBJECT_INTROSPECTION_MIN_VERSION=0.9.6
-GOVIRT_MIN_VERSION=0.1.0
+GOVIRT_MIN_VERSION=0.2.0
GTK_MIN_VERSION=3.5.5
GTK_VNC_MIN_VERSION=0.4.4
LIBVIRT_GLIB_MIN_VERSION=0.1.5
diff --git a/src/ovirt-machine.vala b/src/ovirt-machine.vala
index 1e472d5..6b78874 100644
--- a/src/ovirt-machine.vala
+++ b/src/ovirt-machine.vala
@@ -12,7 +12,7 @@ private class Boxes.OvirtMachine: Boxes.Machine {
base (source, vm.name);
debug ("new ovirt machine: " + name);
- create_display_config (vm.uuid);
+ create_display_config (vm.guid);
this.proxy = proxy;
this.vm = vm;
diff --git a/vapi/govirt-1.0.vapi b/vapi/govirt-1.0.vapi
index 9a56585..03870bf 100644
--- a/vapi/govirt-1.0.vapi
+++ b/vapi/govirt-1.0.vapi
@@ -2,6 +2,12 @@
[CCode (cprefix = "Ovirt", gir_namespace = "GoVirt", gir_version = "1.0", lower_case_cprefix = "ovirt_")]
namespace Ovirt {
+ [CCode (cheader_filename = "govirt/govirt.h", type_id = "ovirt_collection_get_type ()")]
+ public class Collection : GLib.Object {
+ [CCode (has_construct_function = false)]
+ protected Collection ();
+ public unowned GLib.HashTable<string,Ovirt.Resource> get_resources ();
+ }
[CCode (cheader_filename = "govirt/govirt.h", type_id = "ovirt_proxy_get_type ()")]
public class Proxy : Rest.Proxy {
[CCode (has_construct_function = false)]
@@ -17,8 +23,25 @@ namespace Ovirt {
[NoAccessorMethod]
public GLib.ByteArray ca_cert { owned get; set; }
}
+ [CCode (cheader_filename = "govirt/govirt.h", type_id = "ovirt_resource_get_type ()")]
+ public class Resource : GLib.Object, GLib.Initable {
+ [CCode (has_construct_function = false)]
+ protected Resource ();
+ public unowned string get_sub_collection (string sub_collection);
+ [NoWrapper]
+ public virtual bool init_from_xml (Rest.XmlNode node) throws GLib.Error;
+ [NoAccessorMethod]
+ public string description { owned get; set; }
+ [NoAccessorMethod]
+ public string guid { owned get; set; }
+ [NoAccessorMethod]
+ public string href { owned get; set; }
+ [NoAccessorMethod]
+ public string name { owned get; set; }
+ public Rest.XmlNode xml_node { construct; }
+ }
[CCode (cheader_filename = "govirt/govirt.h", type_id = "ovirt_vm_get_type ()")]
- public class Vm : GLib.Object {
+ public class Vm : Ovirt.Resource, GLib.Initable {
[CCode (has_construct_function = false)]
public Vm ();
public bool get_ticket (Ovirt.Proxy proxy) throws GLib.Error;
@@ -31,13 +54,7 @@ namespace Ovirt {
[NoAccessorMethod]
public Ovirt.VmDisplay display { owned get; set; }
[NoAccessorMethod]
- public string href { owned get; set; }
- [NoAccessorMethod]
- public string name { owned get; set; }
- [NoAccessorMethod]
public Ovirt.VmState state { get; set; }
- [NoAccessorMethod]
- public string uuid { owned get; set; }
}
[CCode (cheader_filename = "govirt/govirt.h", type_id = "ovirt_vm_display_get_type ()")]
public class VmDisplay : GLib.Object {
@@ -73,13 +90,28 @@ namespace Ovirt {
public enum VmState {
DOWN,
UP,
- REBOOTING
+ REBOOTING,
+ POWERING_UP,
+ POWERED_DOWN,
+ PAUSED,
+ MIGRATING,
+ UNKNOWN,
+ NOT_RESPONDING,
+ WAIT_FOR_LAUNCH,
+ REBOOT_IN_PROGRESS,
+ SAVING_STATE,
+ RESTORING_STATE,
+ SUSPENDED,
+ IMAGE_LOCKED,
+ POWERING_DOWN
}
- [CCode (cheader_filename = "govirt/govirt.h", cprefix = "OVIRT_PROXY_")]
- public errordomain ProxyError {
+ [CCode (cheader_filename = "govirt/govirt.h", cprefix = "OVIRT_ERROR_")]
+ public errordomain Error {
+ FAILED,
PARSING_FAILED,
+ NOT_SUPPORTED,
ACTION_FAILED,
- FAULT;
+ BAD_URI;
public static GLib.Quark quark ();
}
[CCode (cheader_filename = "govirt/govirt.h", cprefix = "OVIRT_REST_CALL_ERROR_")]
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]