- \ref SD_workstation_management
- \ref SD_link_management
- \ref SD_task_management
- - \ref SD_dependency_management
- - \ref SD_platform_management
+ - \ref SD_task_dependency_management
- \ref SD_simulation
*/
\ingroup SD_API */
/** \addtogroup SD_task_management
\ingroup SD_API */
-/** \addtogroup SD_dependency_management
- \ingroup SD_API */
-/** \addtogroup SD_platform_management
+/** \addtogroup SD_task_dependency_management
\ingroup SD_API */
/** \addtogroup SD_simulation
\ingroup SD_API */
A task is some <em>computing amount</em> that can be executed
in parallel on several workstations. A task may depend on other
tasks, this means that the task cannot start until the other tasks are done.
- Each task has a <em>\ref e_SD_task_state_t "state"</em> indicating whether the task is scheduled, running, done, etc.
+ Each task has a <em>\ref e_SD_task_state_t "state"</em> indicating whether
+ the task is scheduled, running, done, etc.
@see SD_task_management */
typedef struct SD_task *SD_task_t;
/************************** Link handling ***********************************/
-/* private (called by SD_environment_create)
-SD_link_t SD_link_create(void *data, const char *name,
-double bandwidth, double latency);*/
+/** @defgroup SD_link_management Links
+ * @brief Functions for managing the network links
+ *
+ * This section describes the functions for managing the network links.
+ *
+ * A link is a network node represented as a <em>name</em>, a <em>current
+ * bandwidth</em> and a <em>current latency</em>. The links are created
+ * when you call the function SD_create_environment.
+ *
+ * @see SD_link_t
+ * @{
+ */
void* SD_link_get_data(SD_link_t link);
void SD_link_set_data(SD_link_t link, void *data);
const char* SD_link_get_name(SD_link_t link);
-double SD_link_get_capacity(SD_link_t link);
double SD_link_get_current_bandwidth(SD_link_t link);
double SD_link_get_current_latency(SD_link_t link);
-/* private (called by SD_clean)
-void SD_link_destroy(SD_link_t link);
-*/
+/** @} */
/************************** Workstation handling ****************************/
* A workstation is represented as a <em>physical
* resource with computing capabilities</em> and has a <em>name</em>.
*
- * @see SD_workstation_t
+ * The workstations are created when you call the function SD_create_environment.
*
+ * @see SD_workstation_t
* @{
*/
SD_workstation_t SD_workstation_get_by_name(const char *name);
int SD_workstation_route_get_size(SD_workstation_t src, SD_workstation_t dst);
double SD_workstation_get_power(SD_workstation_t workstation);
double SD_workstation_get_available_power(SD_workstation_t workstation);
-
/** @} */
/************************** Task handling ************************************/
+/** @defgroup SD_task_management Tasks
+ * @brief Functions for managing the tasks
+ *
+ * This section describes the functions for managing the tasks.
+ *
+ * A task is some <em>computing amount</em> that can be executed
+ * in parallel on several workstations. A task may depend on other
+ * tasks, this means that the task cannot start until the other tasks are done.
+ * Each task has a <em>\ref e_SD_task_state_t "state"</em> indicating whether
+ * the task is scheduled, running, done, etc.
+ *
+ * @see SD_task_t, SD_task_dependency_management
+ * @{
+ */
SD_task_t SD_task_create(const char *name, void *data, double amount);
-void SD_task_schedule(SD_task_t task, int workstation_nb,
- const SD_workstation_t *workstation_list, double *computation_amount,
- double *communication_amount, double rate);
-void SD_task_reset(SD_task_t task);
void* SD_task_get_data(SD_task_t task);
void SD_task_set_data(SD_task_t task, void *data);
+e_SD_task_state_t SD_task_get_state(SD_task_t task);
const char* SD_task_get_name(SD_task_t task);
double SD_task_get_amount(SD_task_t task);
double SD_task_get_remaining_amount(SD_task_t task);
-void SD_task_dependency_add(const char *name, void *data, SD_task_t src, SD_task_t dst);
-void SD_task_dependency_remove(SD_task_t src, SD_task_t dst);
-void* SD_task_dependency_get_data(SD_task_t src, SD_task_t dst);
-e_SD_task_state_t SD_task_get_state(SD_task_t task);
-/* e_SD_task_state_t can be either SD_SCHEDULED, SD_RUNNING, SD_DONE, or SD_FAILED */
-
void SD_task_watch(SD_task_t task, e_SD_task_state_t state);
-/* SD_simulate will stop as soon as the state of this task is the one given in argument.
- Watch-point is then automatically removed */
-
void SD_task_unwatch(SD_task_t task, e_SD_task_state_t state);
-void SD_task_unschedule(SD_task_t task); /* change state and rerun */
+void SD_task_schedule(SD_task_t task, int workstation_nb,
+ const SD_workstation_t *workstation_list, double *computation_amount,
+ double *communication_amount, double rate);
+void SD_task_unschedule(SD_task_t task);
void SD_task_destroy(SD_task_t task);
+/** @} */
+
+
+/** @defgroup SD_task_dependency_management Tasks dependencies
+ * @brief Functions for managing the task dependencies
+ *
+ * This section describes the functions for managing the dependencies between the tasks.
+ *
+ * @see SD_task_management
+ * @{
+ */
+void SD_task_dependency_add(const char *name, void *data, SD_task_t src, SD_task_t dst);
+void SD_task_dependency_remove(SD_task_t src, SD_task_t dst);
+void* SD_task_dependency_get_data(SD_task_t src, SD_task_t dst);
+/** @} */
/************************** Global *******************************************/
+/** @defgroup SD_simulation Simulation
+ * @brief Functions for creating the environment and launching the simulation
+ *
+ * This section describes the functions for initialising SimDag, launching
+ * the simulation and exiting SimDag.
+ *
+ * @{
+ */
void SD_init(int *argc, char **argv);
void SD_create_environment(const char *platform_file);
-SD_task_t* SD_simulate(double how_long); /* returns a NULL-terminated array of SD_task_t whose state has changed */
-void SD_exit(void); /* cleans everything */
+SD_task_t* SD_simulate(double how_long);
+void SD_exit(void);
+/** @} */
SG_END_DECL()
return task->state_set == sd_global->running_task_set;
}
-
#endif
SD_global_t sd_global = NULL;
-/* Initialises SD internal data. This function should be called before any other SD function.
+/**
+ * \brief Initialises SD internal data
+ *
+ * This function must be called before any other SD function. Then you
+ * should call SD_create_environment().
+ *
+ * \param argc argument number
+ * \param argv argument list
+ * \see SD_create_environment(), SD_exit()
*/
void SD_init(int *argc, char **argv) {
xbt_assert0(sd_global == NULL, "SD_init already called");
surf_init(argc, argv);
}
-/* Creates the environnement described in a xml file of a platform description.
+/**
+ * \brief Creates the environment
+ *
+ * The environment (i.e. the \ref SD_workstation_management "workstations" and the
+ * \ref SD_link_management "links") is created with the data stored in the given XML
+ * platform file.
+ *
+ * \param platform_file name of an XML file describing the environment to create
+ * \see SD_workstation_management, SD_link_management
+ *
+ * The XML file follows this DTD:
+ *
+ * \include surfxml.dtd
+ *
+ * Here is a small example of such a platform:
+ *
+ * \include small_platform.xml
*/
void SD_create_environment(const char *platform_file) {
xbt_dict_cursor_t cursor = NULL;
}
}
-/* Launches the simulation. Returns a NULL-terminated array of SD_task_t whose state has changed.
+/**
+ * \brief Launches the simulation.
+ *
+ * The function will execute the \ref SD_READY ready tasks.
+ * The simulation will be stopped when its time reaches \a how_long,
+ * when a watch point is reached, or when no more task can be executed.
+ * Then you can call SD_simulate() again.
+ *
+ * \param how_long maximum duration of the simulation
+ * \return a NULL-terminated array of \ref SD_task_t whose state has changed.
+ * \see SD_task_schedule(), SD_task_watch()
*/
SD_task_t* SD_simulate(double how_long)
{
return changed_tasks;
}
-/* Destroys all SD internal data. This function should be called when the simulation is over.
- * The tasks should have been destroyed first.
+/**
+ * \brief Destroys all SD internal data.
+ *
+ * This function should be called when the simulation is over. Don't forget also to destroy
+ * the tasks.
+ *
+ * \see SD_init(), SD_task_destroy()
*/
void SD_exit(void) {
if (sd_global != NULL) {
#include "xbt/sysdep.h"
#include "surf/surf.h"
-/* Creates a link.
+/* Creates a link and registers it in SD.
*/
SD_link_t __SD_link_create(void *surf_link, void *data) {
SD_CHECK_INIT_DONE();
link->data = data; /* user data */
const char *name = SD_link_get_name(link);
- xbt_dict_set(sd_global->links, name, link, __SD_link_destroy); /* add the workstation to the dictionary */
+ xbt_dict_set(sd_global->links, name, link, __SD_link_destroy); /* add the link to the dictionary */
return link;
}
-/* Returns the user data of a link. The user data can be NULL.
+/**
+ * \brief Returns the user data of a link
+ *
+ * \param link a link
+ * \return the user data associated with this link (can be \c NULL)
+ * \see SD_link_set_data()
*/
void* SD_link_get_data(SD_link_t link) {
SD_CHECK_INIT_DONE();
return link->data;
}
-/* Sets the user data of a link. The new data can be NULL. The old data should have been freed first if it was not NULL.
+/**
+ * \brief Sets the user data of a link
+ *
+ * The new data can be \c NULL. The old data should have been freed first
+ * if it was not \c NULL.
+ *
+ * \param link a link
+ * \param data the new data you want to associate with this link
+ * \see SD_link_get_data()
*/
void SD_link_set_data(SD_link_t link, void *data) {
SD_CHECK_INIT_DONE();
link->data = data;
}
-/* Returns the name of a link. The name cannot be NULL.
+/**
+ * \brief Returns the name of a link
+ *
+ * \param link a link
+ * \return the name of this link (cannot be \c NULL)
*/
const char* SD_link_get_name(SD_link_t link) {
SD_CHECK_INIT_DONE();
return surf_workstation_resource->extension_public->get_link_name(link->surf_link);
}
-/* Returns the capacity of a link.
- */
-/*
-double SD_link_get_capacity(SD_link_t link) {
- xbt_assert0(link, "Invalid parameter");
- return link->capacity;
-}*/
-
-/* Return the current bandwidth of a link.
+/**
+ * \brief Returns the current bandwidth of a link
+ *
+ * \param link a link
+ * \return the current bandwidth of this link, in Flops
*/
double SD_link_get_current_bandwidth(SD_link_t link) {
SD_CHECK_INIT_DONE();
return surf_workstation_resource->extension_public->get_link_bandwidth(link->surf_link);
}
-/* Return the current latency of a link.
+/**
+ * \brief Returns the current latency of a link
+ *
+ * \param link a link
+ * \return the current latency of this link, in seconds
*/
double SD_link_get_current_latency(SD_link_t link) {
SD_CHECK_INIT_DONE();
return surf_workstation_resource->extension_public->get_link_latency(link->surf_link);
}
-/* Destroys a link. The user data (if any) should have been destroyed first.
+/* Destroys a link.
*/
void __SD_link_destroy(void *link) {
SD_CHECK_INIT_DONE();
#include "xbt/sysdep.h"
#include "xbt/dynar.h"
-/* Creates a task.
+/**
+ * \brief Creates a new task.
+ *
+ * \param name the name of the task (can be \c NULL)
+ * \param data the user data you want to associate with the task (can be \c NULL)
+ * \param amount the computing amount necessary to do this task
+ * \return the new task
+ * \see SD_task_destroy()
*/
SD_task_t SD_task_create(const char *name, void *data, double amount) {
SD_CHECK_INIT_DONE();
return task;
}
-/* Returns the data of a task.
+/**
+ * \brief Returns the user data of a task
+ *
+ * \param task a task
+ * \return the user data associated with this task (can be \c NULL)
+ * \see SD_task_set_data()
*/
void* SD_task_get_data(SD_task_t task) {
SD_CHECK_INIT_DONE();
return task->data;
}
-/* Returns the state of a task: SD_NOT_SCHEDULED, SD_SCHEDULED, SD_READY, SD_RUNNING, SD_DONE or SD_FAILED.
+/**
+ * \brief Sets the user data of a task
+ *
+ * The new data can be \c NULL. The old data should have been freed first
+ * if it was not \c NULL.
+ *
+ * \param task a task
+ * \param data the new data you want to associate with this task
+ * \see SD_task_get_data()
+ */
+void SD_task_set_data(SD_task_t task, void *data) {
+ SD_CHECK_INIT_DONE();
+ xbt_assert0(task != NULL, "Invalid parameter");
+ task->data = data;
+}
+
+/**
+ * \brief Returns the state of a task
+ *
+ * \param task a task
+ * \return the current \ref e_SD_task_state_t "state" of this task:
+ * #SD_NOT_SCHEDULED, #SD_SCHEDULED, #SD_READY, #SD_RUNNING, #SD_DONE or #SD_FAILED
+ * \see e_SD_task_state_t
*/
e_SD_task_state_t SD_task_get_state(SD_task_t task) {
SD_CHECK_INIT_DONE();
default:
xbt_assert0(0, "Invalid state");
}
- xbt_swag_insert(task,task->state_set);
+ xbt_swag_insert(task, task->state_set);
if (task->watch_points & new_state) {
printf("Watch point reached with task '%s' in state %d!\n", SD_task_get_name(task), new_state);
sd_global->watch_point_reached = 1;
+ SD_task_unwatch(task, new_state); /* remove the watch point */
}
}
-/* Sets the data of a task.
- */
-void SD_task_set_data(SD_task_t task, void *data) {
- SD_CHECK_INIT_DONE();
- xbt_assert0(task != NULL, "Invalid parameter");
- task->data = data;
-}
-
-/* Returns the name of a task. The name can be NULL.
+/**
+ * \brief Returns the name of a task
+ *
+ * \param task a task
+ * \return the name of this task (can be \c NULL)
*/
const char* SD_task_get_name(SD_task_t task) {
SD_CHECK_INIT_DONE();
return task->name;
}
-/* Returns the computing amount of a task.
+/**
+ * \brief Returns the computing amount of a task
+ *
+ * \param task a task
+ * \return the total computing amount of this task
+ * \see SD_task_get_remaining_amount()
*/
double SD_task_get_amount(SD_task_t task) {
SD_CHECK_INIT_DONE();
return task->amount;
}
-/* Returns the remaining computing amount of a task.
+/**
+ * \brief Returns the remaining computing amount of a task
+ *
+ * \param task a task
+ * \return the remaining computing amount of this task
+ * \see SD_task_get_amount()
*/
double SD_task_get_remaining_amount(SD_task_t task) {
SD_CHECK_INIT_DONE();
xbt_free(dependency);
}
-/* Adds a dependency between two tasks. Their state must be SD_NOT_SCHEDULED, SD_SCHEDULED
- * or SD_READY.
+/**
+ * \brief Adds a dependency between two tasks
+ *
+ * \a dst will depend on \a src, ie \a dst will not start before \a src is finished.
+ * Their \ref e_SD_task_state_t "state" must be #SD_NOT_SCHEDULED, #SD_SCHEDULED or #SD_READY.
+ *
+ * \param name the name of the new dependency (can be \c NULL)
+ * \param data the user data you want to associate with this dependency (can be \c NULL)
+ * \param src the task which must be executed first
+ * \param dst the task you want to make depend on \a src
+ * \see SD_task_dependency_remove()
*/
void SD_task_dependency_add(const char *name, void *data, SD_task_t src, SD_task_t dst) {
SD_CHECK_INIT_DONE();
__SD_print_dependencies(dst); */
}
-/* Removes a dependency between two tasks.
+/**
+ * \brief Remove a dependency between two tasks
+ *
+ * \param src a task
+ * \param dst a task depending on \a src
+ * \see SD_task_dependency_add()
*/
void SD_task_dependency_remove(SD_task_t src, SD_task_t dst) {
SD_CHECK_INIT_DONE();
__SD_print_dependencies(dst);*/
}
-/* Returns the data associated to a dependency between two tasks. This data can be NULL.
+/**
+ * \brief Returns the user data associated with a dependency between two tasks
+ *
+ * \param src a task
+ * \param dst a task depending on \a src
+ * \return the user data associated with this dependency (can be \c NULL)
+ * \see SD_task_dependency_add()
*/
void *SD_task_dependency_get_data(SD_task_t src, SD_task_t dst) {
SD_CHECK_INIT_DONE();
printf("\n");
}
-/* Adds a watch point to a task.
- SD_simulate will stop as soon as the state of this task is the one given in argument.
- Watch point is then automatically removed.
- The given state must be SD_SCHEDULED, SD_READY, SD_RUNNING, SD_DONE or SD_FAILED.
+/**
+ * \brief Adds a watch point to a task
+ *
+ * SD_simulate() will stop as soon as the \ref e_SD_task_state_t "state" of this task becomes the one given in argument. The
+ * watch point is then automatically removed.
+ *
+ * \param task a task
+ * \param state the \ref e_SD_task_state_t "state" you want to watch (cannot be #SD_NOT_SCHEDULED)
+ * \see SD_task_unwatch()
*/
void SD_task_watch(SD_task_t task, e_SD_task_state_t state) {
SD_CHECK_INIT_DONE();
xbt_assert0(state != SD_NOT_SCHEDULED, "Cannot add a watch point for state SD_NOT_SCHEDULED");
task->watch_points = task->watch_points | state;
- __SD_print_watch_points(task);
+ /* __SD_print_watch_points(task);*/
}
-/* Removes a watch point from a task.
- The given state must be SD_SCHEDULED, SD_READY, SD_RUNNING, SD_DONE or SD_FAILED.
+/**
+ * \brief Removes a watch point from a task
+ *
+ * \param task a task
+ * \param state the \ref e_SD_task_state_t "state" you no longer want to watch
+ * \see SD_task_watch()
*/
void SD_task_unwatch(SD_task_t task, e_SD_task_state_t state) {
SD_CHECK_INIT_DONE();
xbt_assert0(state != SD_NOT_SCHEDULED, "Cannot have a watch point for state SD_NOT_SCHEDULED");
task->watch_points = task->watch_points & ~state;
- __SD_print_watch_points(task);
+ /* __SD_print_watch_points(task);*/
}
/* Destroys the data memorised by SD_task_schedule. Task state must be SD_SCHEDULED or SD_READY.
xbt_free(task->communication_amount);
}
-/* Schedules a task.
- * task: the task to schedule
- * workstation_nb: number of workstations where the task will be executed
- * workstation_list: workstations where the task will be executed
- * computation_amount: computation amount for each workstation
- * communication_amount: communication amount between each pair of workstations
- * rate: task execution speed rate
+/**
+ * \brief Schedules a task
+ *
+ * The task state must be #SD_NOT_SCHEDULED.
+ * Once scheduled, a task will be executed as soon as possible in SD_simulate(),
+ * i.e. when its dependencies are satisfied.
+ *
+ * \param task the task you want to schedule
+ * \param workstation_nb number of workstations on which the task will be executed
+ * \param workstation_list the workstations on which the task will be executed
+ * \param computation_amount computation amount for each workstation
+ * \param communication_amount communication amount between each pair of workstations
+ * \param rate task execution speed rate
+ * \see SD_task_unschedule()
*/
void SD_task_schedule(SD_task_t task, int workstation_nb,
const SD_workstation_t *workstation_list, double *computation_amount,
__SD_task_set_state(task, SD_SCHEDULED);
}
-/* Unschedules a task. The state must be SD_SCHEDULED, SD_READY, SD_RUNNING or SD_FAILED.
- * The task is reinitialised and its state becomes SD_NOT_SCHEDULED.
- * Call SD_task_schedule to schedule it again.
+/**
+ * \brief Unschedules a task
+ *
+ * The task state must be #SD_SCHEDULED, #SD_READY, #SD_RUNNING or #SD_FAILED.
+ * If you call this function, the task state becomes #SD_NOT_SCHEDULED.
+ * Call SD_task_schedule() to schedule it again.
+ *
+ * \param task the task you want to unschedule
+ * \see SD_task_schedule()
*/
void SD_task_unschedule(SD_task_t task) {
SD_CHECK_INIT_DONE();
}
}
-/* Destroys a task. The user data (if any) should have been destroyed first.
+/**
+ * \brief Destroys a task.
+ *
+ * The user data (if any) should have been destroyed first.
+ *
+ * \param task the task you want to destroy
+ * \see SD_task_create()
*/
void SD_task_destroy(SD_task_t task) {
SD_CHECK_INIT_DONE();
return workstation;
}
-/** @ingroup SD_workstation_management
- * @brief Returns a workstation given its name
+/**
+ * \brief Returns a workstation given its name
*
- * If there is no such workstation, the function returns NULL.
+ * If there is no such workstation, the function returns \c NULL.
*
- * @param name workstation name
- * @return the workstation, or NULL if there is no such workstation
+ * \param name workstation name
+ * \return the workstation, or \c NULL if there is no such workstation
*/
SD_workstation_t SD_workstation_get_by_name(const char *name) {
SD_CHECK_INIT_DONE();
return xbt_dict_get_or_null(sd_global->workstations, name);
}
-/** @ingroup SD_workstation_management
- * @brief Returns the workstations list
+/**
+ * \brief Returns the workstations list
*
- * Use SD_workstation_get_number to known the array size.
+ * Use SD_workstation_get_number() to know the array size.
*
- * @return an array of SD_workstation_t containing all workstations
- * @see SD_workstation_get_number
+ * \return an array of \ref SD_workstation_t containing all workstations
+ * \see SD_workstation_get_number()
*/
SD_workstation_t* SD_workstation_get_list(void) {
SD_CHECK_INIT_DONE();
return array;
}
-/** @ingroup SD_workstation_management
- * @brief Returns the number of workstations
+/**
+ * \brief Returns the number of workstations
*
- * @return the number of existing workstations
- * @see SD_workstation_get_list
+ * \return the number of existing workstations
+ * \see SD_workstation_get_list()
*/
int SD_workstation_get_number(void) {
SD_CHECK_INIT_DONE();
return sd_global->workstation_count;
}
-/** @ingroup SD_workstation_management
- * @brief Sets the user data of a workstation
+/**
+ * \brief Returns the user data of a workstation
*
- * The new data can be NULL. The old data should have been freed first
- * if it was not NULL.
- *
- * @param workstation a workstation
- * @param data the new data you want to associate with this workstation
- * @see SD_workstation_get_data
+ * \param workstation a workstation
+ * \return the user data associated with this workstation (can be \c NULL)
+ * \see SD_workstation_set_data()
*/
-void SD_workstation_set_data(SD_workstation_t workstation, void *data) {
+void* SD_workstation_get_data(SD_workstation_t workstation) {
SD_CHECK_INIT_DONE();
xbt_assert0(workstation != NULL, "Invalid parameter");
- workstation->data = data;
+ return workstation->data;
}
-/** @ingroup SD_workstation_management
- * @brief Returns the user data of a workstation
+/**
+ * \brief Sets the user data of a workstation
*
- * @param workstation a workstation
- * @return the user data associated with this workstation (can be NULL)
- * @see SD_workstation_set_data
+ * The new data can be \c NULL. The old data should have been freed first
+ * if it was not \c NULL.
+ *
+ * \param workstation a workstation
+ * \param data the new data you want to associate with this workstation
+ * \see SD_workstation_get_data()
*/
-void* SD_workstation_get_data(SD_workstation_t workstation) {
+void SD_workstation_set_data(SD_workstation_t workstation, void *data) {
SD_CHECK_INIT_DONE();
xbt_assert0(workstation != NULL, "Invalid parameter");
- return workstation->data;
+ workstation->data = data;
}
-/** @ingroup SD_workstation_management
- * @brief Returns the name of a workstation
+/**
+ * \brief Returns the name of a workstation
*
- * @param workstation a workstation
- * @return the name of this workstation (cannot be NULL)
+ * \param workstation a workstation
+ * \return the name of this workstation (cannot be \c NULL)
*/
const char* SD_workstation_get_name(SD_workstation_t workstation) {
SD_CHECK_INIT_DONE();
return surf_workstation_resource->common_public->get_resource_name(workstation->surf_workstation);
}
-/** @ingroup SD_workstation_management
- * @brief Returns the route between two workstations
+/**
+ * \brief Returns the route between two workstations
*
- * Use SD_workstation_route_get_size to known the array size.
+ * Use SD_workstation_route_get_size() to know the array size.
*
- * @param src a workstation
- * @param dst another workstation
- * @return a new array of SD_link_t representating the route between these two workstations
- * @see SD_workstation_route_get_size
+ * \param src a workstation
+ * \param dst another workstation
+ * \return a new array of \ref SD_link_t representating the route between these two workstations
+ * \see SD_workstation_route_get_size(), SD_link_t
*/
SD_link_t* SD_workstation_route_get_list(SD_workstation_t src, SD_workstation_t dst) {
SD_CHECK_INIT_DONE();
return route;
}
-/** @ingroup SD_workstation_management
- * @brief Returns the number of links on the route between two workstations
+/**
+ * \brief Returns the number of links on the route between two workstations
*
- * @param src a workstation
- * @param dst another workstation
- * @return the number of links on the route between these two workstations
- * @see SD_workstation_route_get_list
+ * \param src a workstation
+ * \param dst another workstation
+ * \return the number of links on the route between these two workstations
+ * \see SD_workstation_route_get_list()
*/
int SD_workstation_route_get_size(SD_workstation_t src, SD_workstation_t dst) {
SD_CHECK_INIT_DONE();
get_route_size(src->surf_workstation, dst->surf_workstation);
}
-/** @ingroup SD_workstation_management
- * @brief Returns the total power of a workstation
+/**
+ * \brief Returns the total power of a workstation
*
- * @param workstation a workstation
- * @return the total power of this workstation
- * @see SD_workstation_get_available_power
+ * \param workstation a workstation
+ * \return the total power of this workstation
+ * \see SD_workstation_get_available_power()
*/
double SD_workstation_get_power(SD_workstation_t workstation) {
SD_CHECK_INIT_DONE();
return surf_workstation_resource->extension_public->get_speed(workstation->surf_workstation, 1.0);
}
-/** @ingroup SD_workstation_management
- * @brief Returns the proportion of available power in a workstation
+/**
+ * \brief Returns the proportion of available power in a workstation
*
- * @param workstation a workstation
- * @return the proportion of power currently available in this workstation (normally a number between 0 and 1)
- * @see SD_workstation_get_power
+ * \param workstation a workstation
+ * \return the proportion of power currently available in this workstation (normally a number between 0 and 1)
+ * \see SD_workstation_get_power()
*/
double SD_workstation_get_available_power(SD_workstation_t workstation) {
SD_CHECK_INIT_DONE();