mirror of
https://github.com/OpenNebula/one.git
synced 2025-02-08 05:57:23 +03:00
feature #1224: Get rid of unused method in VirtualMachine
This commit is contained in:
parent
4a92a51e04
commit
7c81925207
@ -949,13 +949,6 @@ public:
|
||||
*/
|
||||
int set_active_snapshot(int snap_id);
|
||||
|
||||
/**
|
||||
* Returns the snapshot with an active operation
|
||||
*
|
||||
* @return the snapshot with an active operation, or 0
|
||||
*/
|
||||
VectorAttribute* get_active_snapshot();
|
||||
|
||||
/**
|
||||
* Replaces HYPERVISOR_ID for the active SNAPSHOT
|
||||
*
|
||||
|
@ -1892,7 +1892,7 @@ int VirtualMachine::set_active_snapshot(int snap_id)
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
|
||||
VectorAttribute* VirtualMachine::get_active_snapshot()
|
||||
void VirtualMachine::update_snapshot_id(string& hypervisor_id)
|
||||
{
|
||||
int num_snaps;
|
||||
vector<Attribute *> snaps;
|
||||
@ -1911,28 +1911,10 @@ VectorAttribute* VirtualMachine::get_active_snapshot()
|
||||
|
||||
if ( snap->vector_value("ACTIVE") == "YES" )
|
||||
{
|
||||
return snap;
|
||||
snap->replace("HYPERVISOR_ID", hypervisor_id);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
|
||||
void VirtualMachine::update_snapshot_id(string& hypervisor_id)
|
||||
{
|
||||
VectorAttribute* snap;
|
||||
|
||||
snap = get_active_snapshot();
|
||||
|
||||
if (snap == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
snap->replace("HYPERVISOR_ID", hypervisor_id);
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
|
Loading…
x
Reference in New Issue
Block a user