|
SimGrid
3.14.159
Versatile Simulation of Distributed Systems
|
Describes the c bindings of SURF.
Typedefs | |
| typedef surf_Model * | surf_model_t |
| Model datatype. More... | |
| typedef surf_Action * | surf_action_t |
| Action structure. More... | |
| surf_action_t | surf_model_extract_done_action_set (surf_model_t model) |
| Pop an action from the done actions set. More... | |
| surf_action_t | surf_model_extract_failed_action_set (surf_model_t model) |
| Pop an action from the failed actions set. More... | |
| int | surf_model_running_action_set_size (surf_model_t model) |
| Get the size of the running action set of a model. More... | |
| surf_action_t | surf_host_open (sg_host_t host, const char *fullpath) |
| Create a file opening action on the given host. More... | |
| surf_action_t | surf_host_close (sg_host_t host, surf_file_t fd) |
| Create a file closing action on the given host. More... | |
| surf_action_t | surf_host_read (sg_host_t host, surf_file_t fd, sg_size_t size) |
| Create a file reading action on the given host. More... | |
| surf_action_t | surf_host_write (sg_host_t host, surf_file_t fd, sg_size_t size) |
| Create a file writing action on the given host. More... | |
| xbt_dynar_t | surf_host_get_info (sg_host_t host, surf_file_t fd) |
| Get the information of a file descriptor. More... | |
| sg_size_t | surf_host_get_free_size (sg_host_t resource, const char *name) |
| Get the available space of the storage at the mount point. More... | |
| sg_size_t | surf_host_get_used_size (sg_host_t resource, const char *name) |
| Get the used space of the storage at the mount point. More... | |
| int | surf_host_unlink (sg_host_t host, surf_file_t fd) |
| Unlink a file descriptor. More... | |
| size_t | surf_host_get_size (sg_host_t host, surf_file_t fd) |
| Get the size of a file on a host. More... | |
| size_t | surf_host_file_tell (sg_host_t host, surf_file_t fd) |
| Get the current position of the file descriptor. More... | |
| int | surf_host_file_move (sg_host_t host, surf_file_t fd, const char *fullpath) |
| Move a file to another location on the same mount point. More... | |
| int | surf_host_file_seek (sg_host_t host, surf_file_t fd, sg_offset_t offset, int origin) |
| Set the position indictator assiociated with the file descriptor to a new position. More... | |
| xbt_dict_t | surf_storage_get_content (surf_resource_t resource) |
| Get the content of a storage. More... | |
| sg_size_t | surf_storage_get_size (surf_resource_t resource) |
| Get the size in bytes of a storage. More... | |
| sg_size_t | surf_storage_get_free_size (surf_resource_t resource) |
| Get the available size in bytes of a storage. More... | |
| sg_size_t | surf_storage_get_used_size (surf_resource_t resource) |
| Get the size in bytes of a storage. More... | |
| xbt_dict_t | surf_storage_get_properties (surf_resource_t resource) |
| return the properties set associated to that storage More... | |
| void | surf_cpu_action_set_bound (surf_action_t action, double bound) |
| [brief description] More... | |
| double | surf_network_action_get_latency_limited (surf_action_t action) |
| [brief description] More... | |
| surf_file_t | surf_storage_action_get_file (surf_action_t action) |
| Get the file associated to a storage action. More... | |
| xbt_dict_t | surf_storage_action_get_ls_dict (surf_action_t action) |
| Get the result dictionary of an ls action. More... | |
| const char * | surf_storage_get_host (surf_resource_t resource) |
| Get the host the storage is attached to. More... | |
| typedef surf_Model* surf_model_t |
Model datatype.
Generic data structure for a model. The hosts, the CPUs and the network links are examples of models.
| typedef surf_Action* surf_action_t |
Action structure.
Never create s_surf_action_t by yourself ! The actions are created on the fly when you call execute or communicate on a model.
| surf_action_t surf_model_extract_done_action_set | ( | surf_model_t | model | ) |
Pop an action from the done actions set.
| model | The model from which the action is extracted |
| surf_action_t surf_model_extract_failed_action_set | ( | surf_model_t | model | ) |
Pop an action from the failed actions set.
| model | The model from which the action is extracted |
| int surf_model_running_action_set_size | ( | surf_model_t | model | ) |
Get the size of the running action set of a model.
| model | The model |
| surf_action_t surf_host_open | ( | sg_host_t | host, |
| const char * | fullpath | ||
| ) |
Create a file opening action on the given host.
| surf_action_t surf_host_close | ( | sg_host_t | host, |
| surf_file_t | fd | ||
| ) |
Create a file closing action on the given host.
| surf_action_t surf_host_read | ( | sg_host_t | host, |
| surf_file_t | fd, | ||
| sg_size_t | size | ||
| ) |
Create a file reading action on the given host.
| surf_action_t surf_host_write | ( | sg_host_t | host, |
| surf_file_t | fd, | ||
| sg_size_t | size | ||
| ) |
Create a file writing action on the given host.
| xbt_dynar_t surf_host_get_info | ( | sg_host_t | host, |
| surf_file_t | fd | ||
| ) |
Get the information of a file descriptor.
The returned xbt_dynar_t contains:
| host | The surf host |
| fd | The file descriptor |
Get the available space of the storage at the mount point.
| resource | The surf host |
| name | The mount point |
Get the used space of the storage at the mount point.
| resource | The surf host |
| name | The mount point |
| int surf_host_unlink | ( | sg_host_t | host, |
| surf_file_t | fd | ||
| ) |
Unlink a file descriptor.
| host | The surf host |
| fd | The file descriptor |
| size_t surf_host_get_size | ( | sg_host_t | host, |
| surf_file_t | fd | ||
| ) |
Get the size of a file on a host.
| host | The surf host |
| fd | The file descriptor |
| size_t surf_host_file_tell | ( | sg_host_t | host, |
| surf_file_t | fd | ||
| ) |
Get the current position of the file descriptor.
| host | The surf host |
| fd | The file descriptor |
| int surf_host_file_move | ( | sg_host_t | host, |
| surf_file_t | fd, | ||
| const char * | fullpath | ||
| ) |
Move a file to another location on the same mount point.
[long description]
| host | The surf host |
| fd | The file descriptor |
| fullpath | The new full path |
| int surf_host_file_seek | ( | sg_host_t | host, |
| surf_file_t | fd, | ||
| sg_offset_t | offset, | ||
| int | origin | ||
| ) |
Set the position indictator assiociated with the file descriptor to a new position.
[long description]
| host | The surf host |
| fd | The file descriptor |
| offset | The offset from the origin |
| origin | Position used as a reference for the offset
|
| xbt_dict_t surf_storage_get_content | ( | surf_resource_t | resource | ) |
Get the content of a storage.
| resource | The surf storage |
| sg_size_t surf_storage_get_size | ( | surf_resource_t | resource | ) |
Get the size in bytes of a storage.
| resource | The surf storage |
| sg_size_t surf_storage_get_free_size | ( | surf_resource_t | resource | ) |
Get the available size in bytes of a storage.
| resource | The surf storage |
| sg_size_t surf_storage_get_used_size | ( | surf_resource_t | resource | ) |
Get the size in bytes of a storage.
| resource | The surf storage |
| xbt_dict_t surf_storage_get_properties | ( | surf_resource_t | resource | ) |
return the properties set associated to that storage
| void surf_cpu_action_set_bound | ( | surf_action_t | action, |
| double | bound | ||
| ) |
[brief description]
[long description]
| action | The surf cpu action |
| bound | [description] |
| double surf_network_action_get_latency_limited | ( | surf_action_t | action | ) |
[brief description]
[long description]
| action | The surf network action |
| surf_file_t surf_storage_action_get_file | ( | surf_action_t | action | ) |
Get the file associated to a storage action.
| action | The surf storage action |
| xbt_dict_t surf_storage_action_get_ls_dict | ( | surf_action_t | action | ) |
Get the result dictionary of an ls action.
| action | The surf storage action |
| const char* surf_storage_get_host | ( | surf_resource_t | resource | ) |
Get the host the storage is attached to.
| resource | The surf storage |