/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this Console /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("protocol")) { protocol = (console_protocol)Helper.EnumParseDefault(typeof(console_protocol), Marshalling.ParseString(table, "protocol")); } if (table.ContainsKey("location")) { location = Marshalling.ParseString(table, "location"); } if (table.ContainsKey("VM")) { VM = Marshalling.ParseRef <VM>(table, "VM"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } }
/// <summary> /// Creates a new VMPP from a Hashtable. /// </summary> /// <param name="table"></param> public VMPP(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); name_label = Marshalling.ParseString(table, "name_label"); name_description = Marshalling.ParseString(table, "name_description"); is_policy_enabled = Marshalling.ParseBool(table, "is_policy_enabled"); backup_type = (vmpp_backup_type)Helper.EnumParseDefault(typeof(vmpp_backup_type), Marshalling.ParseString(table, "backup_type")); backup_retention_value = Marshalling.ParseLong(table, "backup_retention_value"); backup_frequency = (vmpp_backup_frequency)Helper.EnumParseDefault(typeof(vmpp_backup_frequency), Marshalling.ParseString(table, "backup_frequency")); backup_schedule = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "backup_schedule")); is_backup_running = Marshalling.ParseBool(table, "is_backup_running"); backup_last_run_time = Marshalling.ParseDateTime(table, "backup_last_run_time"); archive_target_type = (vmpp_archive_target_type)Helper.EnumParseDefault(typeof(vmpp_archive_target_type), Marshalling.ParseString(table, "archive_target_type")); archive_target_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "archive_target_config")); archive_frequency = (vmpp_archive_frequency)Helper.EnumParseDefault(typeof(vmpp_archive_frequency), Marshalling.ParseString(table, "archive_frequency")); archive_schedule = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "archive_schedule")); is_archive_running = Marshalling.ParseBool(table, "is_archive_running"); archive_last_run_time = Marshalling.ParseDateTime(table, "archive_last_run_time"); VMs = Marshalling.ParseSetRef <VM>(table, "VMs"); is_alarm_enabled = Marshalling.ParseBool(table, "is_alarm_enabled"); alarm_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "alarm_config")); recent_alerts = Marshalling.ParseStringArray(table, "recent_alerts"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this PVS_server /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("addresses")) { addresses = Marshalling.ParseStringArray(table, "addresses"); } if (table.ContainsKey("first_port")) { first_port = Marshalling.ParseLong(table, "first_port"); } if (table.ContainsKey("last_port")) { last_port = Marshalling.ParseLong(table, "last_port"); } if (table.ContainsKey("site")) { site = Marshalling.ParseRef <PVS_site>(table, "site"); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this Vdi_nbd_server_info /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("exportname")) { exportname = Marshalling.ParseString(table, "exportname"); } if (table.ContainsKey("address")) { address = Marshalling.ParseString(table, "address"); } if (table.ContainsKey("port")) { port = Marshalling.ParseLong(table, "port"); } if (table.ContainsKey("cert")) { cert = Marshalling.ParseString(table, "cert"); } if (table.ContainsKey("subject")) { subject = Marshalling.ParseString(table, "subject"); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this Tunnel /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("access_PIF")) { access_PIF = Marshalling.ParseRef <PIF>(table, "access_PIF"); } if (table.ContainsKey("transport_PIF")) { transport_PIF = Marshalling.ParseRef <PIF>(table, "transport_PIF"); } if (table.ContainsKey("status")) { status = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "status")); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VLAN /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("tagged_PIF")) { tagged_PIF = Marshalling.ParseRef <PIF>(table, "tagged_PIF"); } if (table.ContainsKey("untagged_PIF")) { untagged_PIF = Marshalling.ParseRef <PIF>(table, "untagged_PIF"); } if (table.ContainsKey("tag")) { tag = Marshalling.ParseLong(table, "tag"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VIF_metrics /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("io_read_kbs")) { io_read_kbs = Marshalling.ParseDouble(table, "io_read_kbs"); } if (table.ContainsKey("io_write_kbs")) { io_write_kbs = Marshalling.ParseDouble(table, "io_write_kbs"); } if (table.ContainsKey("last_updated")) { last_updated = Marshalling.ParseDateTime(table, "last_updated"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } }
/// <summary> /// Creates a new VIF from a Hashtable. /// </summary> /// <param name="table"></param> public VIF(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); allowed_operations = Helper.StringArrayToEnumList <vif_operations>(Marshalling.ParseStringArray(table, "allowed_operations")); current_operations = Maps.convert_from_proxy_string_vif_operations(Marshalling.ParseHashTable(table, "current_operations")); device = Marshalling.ParseString(table, "device"); network = Marshalling.ParseRef <Network>(table, "network"); VM = Marshalling.ParseRef <VM>(table, "VM"); MAC = Marshalling.ParseString(table, "MAC"); MTU = Marshalling.ParseLong(table, "MTU"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); currently_attached = Marshalling.ParseBool(table, "currently_attached"); status_code = Marshalling.ParseLong(table, "status_code"); status_detail = Marshalling.ParseString(table, "status_detail"); runtime_properties = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "runtime_properties")); qos_algorithm_type = Marshalling.ParseString(table, "qos_algorithm_type"); qos_algorithm_params = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "qos_algorithm_params")); qos_supported_algorithms = Marshalling.ParseStringArray(table, "qos_supported_algorithms"); metrics = Marshalling.ParseRef <VIF_metrics>(table, "metrics"); MAC_autogenerated = Marshalling.ParseBool(table, "MAC_autogenerated"); locking_mode = (vif_locking_mode)Helper.EnumParseDefault(typeof(vif_locking_mode), Marshalling.ParseString(table, "locking_mode")); ipv4_allowed = Marshalling.ParseStringArray(table, "ipv4_allowed"); ipv6_allowed = Marshalling.ParseStringArray(table, "ipv6_allowed"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this GPU_group /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("name_label")) { name_label = Marshalling.ParseString(table, "name_label"); } if (table.ContainsKey("name_description")) { name_description = Marshalling.ParseString(table, "name_description"); } if (table.ContainsKey("PGPUs")) { PGPUs = Marshalling.ParseSetRef <PGPU>(table, "PGPUs"); } if (table.ContainsKey("VGPUs")) { VGPUs = Marshalling.ParseSetRef <VGPU>(table, "VGPUs"); } if (table.ContainsKey("GPU_types")) { GPU_types = Marshalling.ParseStringArray(table, "GPU_types"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } if (table.ContainsKey("allocation_algorithm")) { allocation_algorithm = (allocation_algorithm)Helper.EnumParseDefault(typeof(allocation_algorithm), Marshalling.ParseString(table, "allocation_algorithm")); } if (table.ContainsKey("supported_VGPU_types")) { supported_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "supported_VGPU_types"); } if (table.ContainsKey("enabled_VGPU_types")) { enabled_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "enabled_VGPU_types"); } }
/// <summary> /// Creates a new PGPU from a Hashtable. /// </summary> /// <param name="table"></param> public PGPU(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); PCI = Marshalling.ParseRef <PCI>(table, "PCI"); GPU_group = Marshalling.ParseRef <GPU_group>(table, "GPU_group"); host = Marshalling.ParseRef <Host>(table, "host"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); supported_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "supported_VGPU_types"); enabled_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "enabled_VGPU_types"); resident_VGPUs = Marshalling.ParseSetRef <VGPU>(table, "resident_VGPUs"); supported_VGPU_max_capacities = Maps.convert_from_proxy_XenRefVGPU_type_long(Marshalling.ParseHashTable(table, "supported_VGPU_max_capacities")); dom0_access = (pgpu_dom0_access)Helper.EnumParseDefault(typeof(pgpu_dom0_access), Marshalling.ParseString(table, "dom0_access")); is_system_display_device = Marshalling.ParseBool(table, "is_system_display_device"); compatibility_metadata = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "compatibility_metadata")); }
/// <summary> /// Creates a new PIF from a Hashtable. /// </summary> /// <param name="table"></param> public PIF(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); device = Marshalling.ParseString(table, "device"); network = Marshalling.ParseRef <Network>(table, "network"); host = Marshalling.ParseRef <Host>(table, "host"); MAC = Marshalling.ParseString(table, "MAC"); MTU = Marshalling.ParseLong(table, "MTU"); VLAN = Marshalling.ParseLong(table, "VLAN"); metrics = Marshalling.ParseRef <PIF_metrics>(table, "metrics"); physical = Marshalling.ParseBool(table, "physical"); currently_attached = Marshalling.ParseBool(table, "currently_attached"); ip_configuration_mode = (ip_configuration_mode)Helper.EnumParseDefault(typeof(ip_configuration_mode), Marshalling.ParseString(table, "ip_configuration_mode")); IP = Marshalling.ParseString(table, "IP"); netmask = Marshalling.ParseString(table, "netmask"); gateway = Marshalling.ParseString(table, "gateway"); DNS = Marshalling.ParseString(table, "DNS"); bond_slave_of = Marshalling.ParseRef <Bond>(table, "bond_slave_of"); bond_master_of = Marshalling.ParseSetRef <Bond>(table, "bond_master_of"); VLAN_master_of = Marshalling.ParseRef <VLAN>(table, "VLAN_master_of"); VLAN_slave_of = Marshalling.ParseSetRef <VLAN>(table, "VLAN_slave_of"); management = Marshalling.ParseBool(table, "management"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); disallow_unplug = Marshalling.ParseBool(table, "disallow_unplug"); tunnel_access_PIF_of = Marshalling.ParseSetRef <Tunnel>(table, "tunnel_access_PIF_of"); tunnel_transport_PIF_of = Marshalling.ParseSetRef <Tunnel>(table, "tunnel_transport_PIF_of"); ipv6_configuration_mode = (ipv6_configuration_mode)Helper.EnumParseDefault(typeof(ipv6_configuration_mode), Marshalling.ParseString(table, "ipv6_configuration_mode")); IPv6 = Marshalling.ParseStringArray(table, "IPv6"); ipv6_gateway = Marshalling.ParseString(table, "ipv6_gateway"); primary_address_type = (primary_address_type)Helper.EnumParseDefault(typeof(primary_address_type), Marshalling.ParseString(table, "primary_address_type")); }
/// <summary> /// Creates a new LVHD from a Hashtable. /// </summary> /// <param name="table"></param> public LVHD(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); }
/// <summary> /// Creates a new Task from a Hashtable. /// </summary> /// <param name="table"></param> public Task(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); name_label = Marshalling.ParseString(table, "name_label"); name_description = Marshalling.ParseString(table, "name_description"); allowed_operations = Helper.StringArrayToEnumList <task_allowed_operations>(Marshalling.ParseStringArray(table, "allowed_operations")); current_operations = Maps.convert_from_proxy_string_task_allowed_operations(Marshalling.ParseHashTable(table, "current_operations")); created = Marshalling.ParseDateTime(table, "created"); finished = Marshalling.ParseDateTime(table, "finished"); status = (task_status_type)Helper.EnumParseDefault(typeof(task_status_type), Marshalling.ParseString(table, "status")); resident_on = Marshalling.ParseRef <Host>(table, "resident_on"); progress = Marshalling.ParseDouble(table, "progress"); type = Marshalling.ParseString(table, "type"); result = Marshalling.ParseString(table, "result"); error_info = Marshalling.ParseStringArray(table, "error_info"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); subtask_of = Marshalling.ParseRef <Task>(table, "subtask_of"); subtasks = Marshalling.ParseSetRef <Task>(table, "subtasks"); }
/// <summary> /// Creates a new GPU_group from a Hashtable. /// </summary> /// <param name="table"></param> public GPU_group(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); name_label = Marshalling.ParseString(table, "name_label"); name_description = Marshalling.ParseString(table, "name_description"); PGPUs = Marshalling.ParseSetRef <PGPU>(table, "PGPUs"); VGPUs = Marshalling.ParseSetRef <VGPU>(table, "VGPUs"); GPU_types = Marshalling.ParseStringArray(table, "GPU_types"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); allocation_algorithm = (allocation_algorithm)Helper.EnumParseDefault(typeof(allocation_algorithm), Marshalling.ParseString(table, "allocation_algorithm")); supported_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "supported_VGPU_types"); enabled_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "enabled_VGPU_types"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VM_metrics /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("memory_actual")) { memory_actual = Marshalling.ParseLong(table, "memory_actual"); } if (table.ContainsKey("VCPUs_number")) { VCPUs_number = Marshalling.ParseLong(table, "VCPUs_number"); } if (table.ContainsKey("VCPUs_utilisation")) { VCPUs_utilisation = Maps.convert_from_proxy_long_double(Marshalling.ParseHashTable(table, "VCPUs_utilisation")); } if (table.ContainsKey("VCPUs_CPU")) { VCPUs_CPU = Maps.convert_from_proxy_long_long(Marshalling.ParseHashTable(table, "VCPUs_CPU")); } if (table.ContainsKey("VCPUs_params")) { VCPUs_params = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "VCPUs_params")); } if (table.ContainsKey("VCPUs_flags")) { VCPUs_flags = Maps.convert_from_proxy_long_string_array(Marshalling.ParseHashTable(table, "VCPUs_flags")); } if (table.ContainsKey("state")) { state = Marshalling.ParseStringArray(table, "state"); } if (table.ContainsKey("start_time")) { start_time = Marshalling.ParseDateTime(table, "start_time"); } if (table.ContainsKey("install_time")) { install_time = Marshalling.ParseDateTime(table, "install_time"); } if (table.ContainsKey("last_updated")) { last_updated = Marshalling.ParseDateTime(table, "last_updated"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } if (table.ContainsKey("hvm")) { hvm = Marshalling.ParseBool(table, "hvm"); } if (table.ContainsKey("nested_virt")) { nested_virt = Marshalling.ParseBool(table, "nested_virt"); } if (table.ContainsKey("nomigrate")) { nomigrate = Marshalling.ParseBool(table, "nomigrate"); } if (table.ContainsKey("current_domain_type")) { current_domain_type = (domain_type)Helper.EnumParseDefault(typeof(domain_type), Marshalling.ParseString(table, "current_domain_type")); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this PVS_proxy /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("site")) { site = Marshalling.ParseRef <PVS_site>(table, "site"); } if (table.ContainsKey("VIF")) { VIF = Marshalling.ParseRef <VIF>(table, "VIF"); } if (table.ContainsKey("currently_attached")) { currently_attached = Marshalling.ParseBool(table, "currently_attached"); } if (table.ContainsKey("status")) { status = (pvs_proxy_status)Helper.EnumParseDefault(typeof(pvs_proxy_status), Marshalling.ParseString(table, "status")); } }
/// <summary> /// Creates a new Network from a Hashtable. /// </summary> /// <param name="table"></param> public Network(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); name_label = Marshalling.ParseString(table, "name_label"); name_description = Marshalling.ParseString(table, "name_description"); allowed_operations = Helper.StringArrayToEnumList <network_operations>(Marshalling.ParseStringArray(table, "allowed_operations")); current_operations = Maps.convert_from_proxy_string_network_operations(Marshalling.ParseHashTable(table, "current_operations")); VIFs = Marshalling.ParseSetRef <VIF>(table, "VIFs"); PIFs = Marshalling.ParseSetRef <PIF>(table, "PIFs"); MTU = Marshalling.ParseLong(table, "MTU"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); bridge = Marshalling.ParseString(table, "bridge"); managed = Marshalling.ParseBool(table, "managed"); blobs = Maps.convert_from_proxy_string_XenRefBlob(Marshalling.ParseHashTable(table, "blobs")); tags = Marshalling.ParseStringArray(table, "tags"); default_locking_mode = (network_default_locking_mode)Helper.EnumParseDefault(typeof(network_default_locking_mode), Marshalling.ParseString(table, "default_locking_mode")); assigned_ips = Maps.convert_from_proxy_XenRefVIF_string(Marshalling.ParseHashTable(table, "assigned_ips")); purpose = Helper.StringArrayToEnumList <network_purpose>(Marshalling.ParseStringArray(table, "purpose")); }
/// <summary> /// Creates a new DR_task from a Hashtable. /// </summary> /// <param name="table"></param> public DR_task(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); introduced_SRs = Marshalling.ParseSetRef <SR>(table, "introduced_SRs"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this Task /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("name_label")) { name_label = Marshalling.ParseString(table, "name_label"); } if (table.ContainsKey("name_description")) { name_description = Marshalling.ParseString(table, "name_description"); } if (table.ContainsKey("allowed_operations")) { allowed_operations = Helper.StringArrayToEnumList <task_allowed_operations>(Marshalling.ParseStringArray(table, "allowed_operations")); } if (table.ContainsKey("current_operations")) { current_operations = Maps.convert_from_proxy_string_task_allowed_operations(Marshalling.ParseHashTable(table, "current_operations")); } if (table.ContainsKey("created")) { created = Marshalling.ParseDateTime(table, "created"); } if (table.ContainsKey("finished")) { finished = Marshalling.ParseDateTime(table, "finished"); } if (table.ContainsKey("status")) { status = (task_status_type)Helper.EnumParseDefault(typeof(task_status_type), Marshalling.ParseString(table, "status")); } if (table.ContainsKey("resident_on")) { resident_on = Marshalling.ParseRef <Host>(table, "resident_on"); } if (table.ContainsKey("progress")) { progress = Marshalling.ParseDouble(table, "progress"); } if (table.ContainsKey("type")) { type = Marshalling.ParseString(table, "type"); } if (table.ContainsKey("result")) { result = Marshalling.ParseString(table, "result"); } if (table.ContainsKey("error_info")) { error_info = Marshalling.ParseStringArray(table, "error_info"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } if (table.ContainsKey("subtask_of")) { subtask_of = Marshalling.ParseRef <Task>(table, "subtask_of"); } if (table.ContainsKey("subtasks")) { subtasks = Marshalling.ParseSetRef <Task>(table, "subtasks"); } if (table.ContainsKey("backtrace")) { backtrace = Marshalling.ParseString(table, "backtrace"); } }
/// <summary> /// Creates a new VM_guest_metrics from a Hashtable. /// </summary> /// <param name="table"></param> public VM_guest_metrics(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); os_version = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "os_version")); PV_drivers_version = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "PV_drivers_version")); PV_drivers_up_to_date = Marshalling.ParseBool(table, "PV_drivers_up_to_date"); memory = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "memory")); disks = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "disks")); networks = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "networks")); other = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other")); last_updated = Marshalling.ParseDateTime(table, "last_updated"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); live = Marshalling.ParseBool(table, "live"); can_use_hotplug_vbd = (tristate_type)Helper.EnumParseDefault(typeof(tristate_type), Marshalling.ParseString(table, "can_use_hotplug_vbd")); can_use_hotplug_vif = (tristate_type)Helper.EnumParseDefault(typeof(tristate_type), Marshalling.ParseString(table, "can_use_hotplug_vif")); PV_drivers_detected = Marshalling.ParseBool(table, "PV_drivers_detected"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VMSS /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("name_label")) { name_label = Marshalling.ParseString(table, "name_label"); } if (table.ContainsKey("name_description")) { name_description = Marshalling.ParseString(table, "name_description"); } if (table.ContainsKey("enabled")) { enabled = Marshalling.ParseBool(table, "enabled"); } if (table.ContainsKey("type")) { type = (vmss_type)Helper.EnumParseDefault(typeof(vmss_type), Marshalling.ParseString(table, "type")); } if (table.ContainsKey("retained_snapshots")) { retained_snapshots = Marshalling.ParseLong(table, "retained_snapshots"); } if (table.ContainsKey("frequency")) { frequency = (vmss_frequency)Helper.EnumParseDefault(typeof(vmss_frequency), Marshalling.ParseString(table, "frequency")); } if (table.ContainsKey("schedule")) { schedule = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "schedule")); } if (table.ContainsKey("last_run_time")) { last_run_time = Marshalling.ParseDateTime(table, "last_run_time"); } if (table.ContainsKey("VMs")) { VMs = Marshalling.ParseSetRef <VM>(table, "VMs"); } }
/// <summary> /// Creates a new SDN_controller from a Hashtable. /// </summary> /// <param name="table"></param> public SDN_controller(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); protocol = (sdn_controller_protocol)Helper.EnumParseDefault(typeof(sdn_controller_protocol), Marshalling.ParseString(table, "protocol")); address = Marshalling.ParseString(table, "address"); port = Marshalling.ParseLong(table, "port"); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VGPU_type /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("vendor_name")) { vendor_name = Marshalling.ParseString(table, "vendor_name"); } if (table.ContainsKey("model_name")) { model_name = Marshalling.ParseString(table, "model_name"); } if (table.ContainsKey("framebuffer_size")) { framebuffer_size = Marshalling.ParseLong(table, "framebuffer_size"); } if (table.ContainsKey("max_heads")) { max_heads = Marshalling.ParseLong(table, "max_heads"); } if (table.ContainsKey("max_resolution_x")) { max_resolution_x = Marshalling.ParseLong(table, "max_resolution_x"); } if (table.ContainsKey("max_resolution_y")) { max_resolution_y = Marshalling.ParseLong(table, "max_resolution_y"); } if (table.ContainsKey("supported_on_PGPUs")) { supported_on_PGPUs = Marshalling.ParseSetRef <PGPU>(table, "supported_on_PGPUs"); } if (table.ContainsKey("enabled_on_PGPUs")) { enabled_on_PGPUs = Marshalling.ParseSetRef <PGPU>(table, "enabled_on_PGPUs"); } if (table.ContainsKey("VGPUs")) { VGPUs = Marshalling.ParseSetRef <VGPU>(table, "VGPUs"); } if (table.ContainsKey("supported_on_GPU_groups")) { supported_on_GPU_groups = Marshalling.ParseSetRef <GPU_group>(table, "supported_on_GPU_groups"); } if (table.ContainsKey("enabled_on_GPU_groups")) { enabled_on_GPU_groups = Marshalling.ParseSetRef <GPU_group>(table, "enabled_on_GPU_groups"); } if (table.ContainsKey("implementation")) { implementation = (vgpu_type_implementation)Helper.EnumParseDefault(typeof(vgpu_type_implementation), Marshalling.ParseString(table, "implementation")); } if (table.ContainsKey("identifier")) { identifier = Marshalling.ParseString(table, "identifier"); } if (table.ContainsKey("experimental")) { experimental = Marshalling.ParseBool(table, "experimental"); } if (table.ContainsKey("compatible_types_in_vm")) { compatible_types_in_vm = Marshalling.ParseSetRef <VGPU_type>(table, "compatible_types_in_vm"); } }
/// <summary> /// Creates a new VGPU_type from a Hashtable. /// </summary> /// <param name="table"></param> public VGPU_type(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); vendor_name = Marshalling.ParseString(table, "vendor_name"); model_name = Marshalling.ParseString(table, "model_name"); framebuffer_size = Marshalling.ParseLong(table, "framebuffer_size"); max_heads = Marshalling.ParseLong(table, "max_heads"); max_resolution_x = Marshalling.ParseLong(table, "max_resolution_x"); max_resolution_y = Marshalling.ParseLong(table, "max_resolution_y"); supported_on_PGPUs = Marshalling.ParseSetRef <PGPU>(table, "supported_on_PGPUs"); enabled_on_PGPUs = Marshalling.ParseSetRef <PGPU>(table, "enabled_on_PGPUs"); VGPUs = Marshalling.ParseSetRef <VGPU>(table, "VGPUs"); supported_on_GPU_groups = Marshalling.ParseSetRef <GPU_group>(table, "supported_on_GPU_groups"); enabled_on_GPU_groups = Marshalling.ParseSetRef <GPU_group>(table, "enabled_on_GPU_groups"); implementation = (vgpu_type_implementation)Helper.EnumParseDefault(typeof(vgpu_type_implementation), Marshalling.ParseString(table, "implementation")); identifier = Marshalling.ParseString(table, "identifier"); experimental = Marshalling.ParseBool(table, "experimental"); }
/// <summary> /// Creates a new Secret from a Hashtable. /// </summary> /// <param name="table"></param> public Secret(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); value = Marshalling.ParseString(table, "value"); other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this PGPU /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("PCI")) { PCI = Marshalling.ParseRef <PCI>(table, "PCI"); } if (table.ContainsKey("GPU_group")) { GPU_group = Marshalling.ParseRef <GPU_group>(table, "GPU_group"); } if (table.ContainsKey("host")) { host = Marshalling.ParseRef <Host>(table, "host"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } if (table.ContainsKey("supported_VGPU_types")) { supported_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "supported_VGPU_types"); } if (table.ContainsKey("enabled_VGPU_types")) { enabled_VGPU_types = Marshalling.ParseSetRef <VGPU_type>(table, "enabled_VGPU_types"); } if (table.ContainsKey("resident_VGPUs")) { resident_VGPUs = Marshalling.ParseSetRef <VGPU>(table, "resident_VGPUs"); } if (table.ContainsKey("supported_VGPU_max_capacities")) { supported_VGPU_max_capacities = Maps.convert_from_proxy_XenRefVGPU_type_long(Marshalling.ParseHashTable(table, "supported_VGPU_max_capacities")); } if (table.ContainsKey("dom0_access")) { dom0_access = (pgpu_dom0_access)Helper.EnumParseDefault(typeof(pgpu_dom0_access), Marshalling.ParseString(table, "dom0_access")); } if (table.ContainsKey("is_system_display_device")) { is_system_display_device = Marshalling.ParseBool(table, "is_system_display_device"); } if (table.ContainsKey("compatibility_metadata")) { compatibility_metadata = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "compatibility_metadata")); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this SDN_controller /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("protocol")) { protocol = (sdn_controller_protocol)Helper.EnumParseDefault(typeof(sdn_controller_protocol), Marshalling.ParseString(table, "protocol")); } if (table.ContainsKey("address")) { address = Marshalling.ParseString(table, "address"); } if (table.ContainsKey("port")) { port = Marshalling.ParseLong(table, "port"); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this VM_guest_metrics /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("os_version")) { os_version = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "os_version")); } if (table.ContainsKey("PV_drivers_version")) { PV_drivers_version = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "PV_drivers_version")); } if (table.ContainsKey("PV_drivers_up_to_date")) { PV_drivers_up_to_date = Marshalling.ParseBool(table, "PV_drivers_up_to_date"); } if (table.ContainsKey("memory")) { memory = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "memory")); } if (table.ContainsKey("disks")) { disks = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "disks")); } if (table.ContainsKey("networks")) { networks = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "networks")); } if (table.ContainsKey("other")) { other = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other")); } if (table.ContainsKey("last_updated")) { last_updated = Marshalling.ParseDateTime(table, "last_updated"); } if (table.ContainsKey("other_config")) { other_config = Maps.convert_from_proxy_string_string(Marshalling.ParseHashTable(table, "other_config")); } if (table.ContainsKey("live")) { live = Marshalling.ParseBool(table, "live"); } if (table.ContainsKey("can_use_hotplug_vbd")) { can_use_hotplug_vbd = (tristate_type)Helper.EnumParseDefault(typeof(tristate_type), Marshalling.ParseString(table, "can_use_hotplug_vbd")); } if (table.ContainsKey("can_use_hotplug_vif")) { can_use_hotplug_vif = (tristate_type)Helper.EnumParseDefault(typeof(tristate_type), Marshalling.ParseString(table, "can_use_hotplug_vif")); } if (table.ContainsKey("PV_drivers_detected")) { PV_drivers_detected = Marshalling.ParseBool(table, "PV_drivers_detected"); } }
/// <summary> /// Given a Hashtable with field-value pairs, it updates the fields of this Network_sriov /// with the values listed in the Hashtable. Note that only the fields contained /// in the Hashtable will be updated and the rest will remain the same. /// </summary> /// <param name="table"></param> public void UpdateFrom(Hashtable table) { if (table.ContainsKey("uuid")) { uuid = Marshalling.ParseString(table, "uuid"); } if (table.ContainsKey("physical_PIF")) { physical_PIF = Marshalling.ParseRef <PIF>(table, "physical_PIF"); } if (table.ContainsKey("logical_PIF")) { logical_PIF = Marshalling.ParseRef <PIF>(table, "logical_PIF"); } if (table.ContainsKey("requires_reboot")) { requires_reboot = Marshalling.ParseBool(table, "requires_reboot"); } if (table.ContainsKey("configuration_mode")) { configuration_mode = (sriov_configuration_mode)Helper.EnumParseDefault(typeof(sriov_configuration_mode), Marshalling.ParseString(table, "configuration_mode")); } }
/// <summary> /// Creates a new VTPM from a Hashtable. /// </summary> /// <param name="table"></param> public VTPM(Hashtable table) { uuid = Marshalling.ParseString(table, "uuid"); VM = Marshalling.ParseRef <VM>(table, "VM"); backend = Marshalling.ParseRef <VM>(table, "backend"); }