A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
cosmetics
[simgrid.git]
/
src
/
surf
/
virtual_machine.cpp
diff --git
a/src/surf/virtual_machine.cpp
b/src/surf/virtual_machine.cpp
index
8b5946e
..
9be8a78
100644
(file)
--- a/
src/surf/virtual_machine.cpp
+++ b/
src/surf/virtual_machine.cpp
@@
-38,8
+38,7
@@
VirtualMachine::VirtualMachine(Model *model, const char *name, xbt_dict_t props,
: Host(model, name, props, NULL, netElm, cpu)
{
VMModel::ws_vms.push_back(*this);
: Host(model, name, props, NULL, netElm, cpu)
{
VMModel::ws_vms.push_back(*this);
-
- xbt_lib_set(host_lib, name, SURF_HOST_LEVEL, this);
+ simgrid::Host::by_name_or_create(name)->set_facet(SURF_HOST_LEVEL, this);
}
/*
}
/*
@@
-61,9
+60,9
@@
void VirtualMachine::setState(e_surf_resource_state_t state){
* A surf level object will be useless in the upper layer. Returning the
* dict_elm of the host.
**/
* A surf level object will be useless in the upper layer. Returning the
* dict_elm of the host.
**/
-s
urf_resource
_t VirtualMachine::getPm()
+s
g_host
_t VirtualMachine::getPm()
{
{
- return
xbt_lib_get_elm_or_null(host_lib,
p_subWs->getName());
+ return
simgrid::Host::by_name_or_null(
p_subWs->getName());
}
/**********
}
/**********