Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines.
[simgrid.git] / include / simgrid / mailbox.h
1 /* Copyright (c) 2018-2021. The SimGrid Team. All rights reserved.          */
2
3 /* This program is free software; you can redistribute it and/or modify it
4  * under the terms of the license (GNU LGPL) which comes with this package. */
5
6 #ifndef INCLUDE_SIMGRID_MAILBOX_H_
7 #define INCLUDE_SIMGRID_MAILBOX_H_
8
9 #include <simgrid/forward.h>
10 #include <xbt/base.h>
11
12 /* C interface */
13 SG_BEGIN_DECL
14
15 XBT_PUBLIC sg_mailbox_t sg_mailbox_by_name(const char* alias);
16 XBT_PUBLIC const char* sg_mailbox_get_name(const_sg_mailbox_t mailbox);
17 XBT_PUBLIC void sg_mailbox_set_receiver(const char* alias);
18 XBT_PUBLIC int sg_mailbox_listen(const char* alias);
19
20 XBT_PUBLIC sg_comm_t sg_mailbox_put_init(sg_mailbox_t mailbox, void* payload, long simulated_size_in_bytes);
21 XBT_PUBLIC sg_comm_t sg_mailbox_put_async(sg_mailbox_t mailbox, void* payload, long simulated_size_in_bytes);
22 XBT_PUBLIC void sg_mailbox_put(sg_mailbox_t mailbox, void* payload, long simulated_size_in_bytes);
23
24 XBT_PUBLIC sg_comm_t sg_mailbox_get_async(sg_mailbox_t mailbox, void** data);
25 XBT_PUBLIC void* sg_mailbox_get(sg_mailbox_t mailbox);
26
27 SG_END_DECL
28
29 #endif /* INCLUDE_SIMGRID_MAILBOX_H_ */