#include "xbt/lib.h"
#include "xbt/sysdep.h"
#include "surf/surf.h"
-#include "surf/surf_resource.h"
#include "simgrid/msg.h" //FIXME: why?
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(sd_workstation, sd,
* \brief Returns the workstation list
*
* Use SD_workstation_get_number() to know the array size.
- *
+ *
* \return an array of \ref SD_workstation_t containing all workstations
+ * \remark The workstation order in the returned array is generally different from the workstation creation/declaration order in the XML platform (we use a hash table internally).
* \see SD_workstation_get_number()
*/
const SD_workstation_t *SD_workstation_get_list(void)
*/
xbt_dict_t SD_workstation_get_properties(SD_workstation_t workstation)
{
- return surf_resource_get_properties(surf_workstation_resource_priv(workstation));
+ return surf_host_get_properties(surf_host_resource_priv(workstation));
}
surf_src = src;
surf_dst = dst;
- surf_route = surf_workstation_model_get_route((surf_workstation_model_t)surf_workstation_model,
+ surf_route = surf_host_model_get_route((surf_host_model_t)surf_host_model,
surf_src, surf_dst);
xbt_dynar_foreach(surf_route, cpt, surf_link) {
*/
int SD_route_get_size(SD_workstation_t src, SD_workstation_t dst)
{
- return xbt_dynar_length(surf_workstation_model_get_route(
- (surf_workstation_model_t)surf_workstation_model, src, dst));
+ return xbt_dynar_length(surf_host_model_get_route(
+ (surf_host_model_t)surf_host_model, src, dst));
}
/**
*/
double SD_workstation_get_power(SD_workstation_t workstation)
{
- return surf_workstation_get_speed(workstation, 1.0);
+ return surf_host_get_speed(workstation, 1.0);
}
/**
* \brief Returns the amount of cores of a workstation
* \return the amount of cores of this workstation
*/
int SD_workstation_get_cores(SD_workstation_t workstation) {
- return surf_workstation_get_core(workstation);
+ return surf_host_get_core(workstation);
}
/**
*/
double SD_workstation_get_available_power(SD_workstation_t workstation)
{
- return surf_workstation_get_available_speed(workstation);
+ return surf_host_get_available_speed(workstation);
}
/**
* \return a dynar containing all mounted storages on the workstation
*/
xbt_dict_t SD_workstation_get_mounted_storage_list(SD_workstation_t workstation){
- return surf_workstation_get_mounted_storage_list(workstation);
+ return surf_host_get_mounted_storage_list(workstation);
}
/**
* \return a dynar containing all mounted storages on the workstation
*/
xbt_dynar_t SD_workstation_get_attached_storage_list(SD_workstation_t workstation){
- return surf_workstation_get_attached_storage_list(workstation);
+ return surf_host_get_attached_storage_list(workstation);
}
/**