typedef struct RoutingPlatf RoutingPlatf;
#endif
-/** \ingroup SURF_models
+/** @ingroup SURF_c_bindings
* \brief Model datatype
*
* Generic data structure for a model. The workstations,
typedef NetworkCm02Link *surf_network_link_t;
typedef Cpu *surf_cpu_t;
-/** \ingroup SURF_actions
+/** @ingroup SURF_c_bindings
* \brief Action structure
*
* Never create s_surf_action_t by yourself ! The actions are created
* \see e_surf_action_state_t
*/
typedef Action *surf_action_t;
-typedef ActionLmm *surf_action_lmm_t;
-typedef StorageActionLmm *surf_storage_action_lmm_t;
typedef As *AS_t;
typedef RoutingEdge *routing_edge_t;
* @brief Open a file on a workstation
*
* @param workstation The surf workstation
- * @param mount The mount point
- * @param path The path to the file
+ * @param fullpath The path to the file
* @return The surf action corresponding to the openning
*/
-XBT_PUBLIC(surf_action_t) surf_workstation_open(surf_resource_t workstation, const char* mount, const char* path);
+XBT_PUBLIC(surf_action_t) surf_workstation_open(surf_resource_t workstation, const char* fullpath);
/**
* @brief Close a file descriptor on a workstation
XBT_PUBLIC(double) surf_workstation_get_consumed_energy(surf_resource_t host);
/**
- * @brief Get the list of storages of a workstation
+ * @brief Get the list of storages mounted on a workstation
*
* @param workstation The surf workstation
* @return Dictionary of mount point, Storage
*/
-XBT_PUBLIC(xbt_dict_t) surf_workstation_get_storage_list(surf_resource_t workstation);
+XBT_PUBLIC(xbt_dict_t) surf_workstation_get_mounted_storage_list(surf_resource_t workstation);
+
+/**
+ * @brief Get the list of storages attached to a workstation
+ *
+ * @param workstation The surf workstation
+ * @return Dictionary of storage
+ */
+XBT_PUBLIC(xbt_dynar_t) surf_workstation_get_attached_storage_list(surf_resource_t workstation);
/**
* @brief Unlink a file descriptor
*/
XBT_PUBLIC(size_t) surf_workstation_file_tell(surf_resource_t workstation, surf_file_t fd);
+/**
+ * @brief Move a file to another location on the *same mount point*.
+ * @details [long description]
+ *
+ * @param workstation The surf workstation
+ * @param fd The file descriptor
+ * @param fullpath The new full path
+ *
+ * @return MSG_OK if successful, otherwise MSG_TASK_CANCELED
+ */
+XBT_PUBLIC(int) surf_workstation_file_move(surf_resource_t workstation, surf_file_t fd, const char* fullpath);
+
/**
* @brief Set the position indictator assiociated with the file descriptor to a new position
* @details [long description]
*/
XBT_PUBLIC(int) surf_workstation_file_seek(surf_resource_t workstation, surf_file_t fd, sg_size_t offset, int origin);
+
/**
* @brief [brief description]
* @details [long description]
*/
XBT_PUBLIC(sg_size_t) surf_storage_get_size(surf_resource_t resource);
-/**
- * @brief Rename a path
- *
- * @param resource The surf storage
- * @param src The old path
- * @param dest The new path
- */
-XBT_PUBLIC(void) surf_storage_rename(surf_resource_t resource, const char* src, const char* dest);
-
/**
* @brief Get the data associated to the action
*
*/
XBT_PUBLIC(xbt_dict_t) surf_storage_action_get_ls_dict(surf_action_t action);
+
+/**
+ * @brief Get the host the storage is attached to
+ *
+ * @param resource The surf storage
+ * @return The host name
+ */
+XBT_PUBLIC(const char * ) surf_storage_get_host(surf_resource_t resource);
+
XBT_PUBLIC(surf_model_t) surf_resource_model(const void *host, int level);
/** @} */
/* Prototypes of the functions that handle the properties */
XBT_PUBLIC_DATA(xbt_dict_t) current_property_set; /* the prop set for the currently parsed element (also used in SIMIX) */
+/* The same for model_prop set*/
+XBT_PUBLIC_DATA(xbt_dict_t) current_model_property_set;
+
/* surf parse file related (public because called from a test suite) */
XBT_PUBLIC(void) parse_platform_file(const char *file);