class Actor
==============
-.. doxygenclass:: simgrid::s4u::Actor
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Actor
+
+ .. doxygentypedef:: aid_t
-.. doxygentypedef:: aid_t
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Actor
Basic management
----------------
from simgrid import Actor
- .. autoclass:: simgrid.Actor
-
.. group-tab:: C
.. code:: C
Simulation Engine
====================
-.. doxygenclass:: simgrid::s4u::Engine
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Engine
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Engine
Initialization
--------------
class Mailbox
================
-.. doxygenclass:: simgrid::s4u::Mailbox
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Mailbox
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Mailbox
Please also refer to the :ref:`full doc on s4u::Mailbox <s4u_mailbox>`.
#include <simgrid/mailbox.h>
- .. autoclass:: simgrid.Mailbox
-
.. automethod:: simgrid.Mailbox.by_name
.. group-tab:: C
class Disk
=============
-.. doxygenclass:: simgrid::s4u::Disk
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Disk
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Disk
Basic management
----------------
class Host
=============
-.. doxygenclass:: simgrid::s4u::Host
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Host
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Host
Basic management
----------------
class Link
=============
-.. doxygenclass:: simgrid::s4u::Link
-.. doxygenclass:: simgrid::s4u::SplitDuplexLink
-.. doxygenclass:: simgrid::s4u::LinkInRoute
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Link
+ .. doxygenclass:: simgrid::s4u::SplitDuplexLink
+ .. doxygenclass:: simgrid::s4u::LinkInRoute
+
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Link
Basic management
----------------
class NetZone
================
-.. doxygenclass:: simgrid::s4u::NetZone
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::NetZone
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.NetZone
Basic management
----------------
from simgrid import NetZone
- .. autoclass:: simgrid.NetZone
.. automethod:: simgrid.NetZone.seal
.. group-tab:: C
class Comm
=============
-.. doxygenclass:: simgrid::s4u::Comm
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Comm
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Comm
Basic management
----------------
from simgrid import Comm
- .. autoclass:: simgrid.Comm
-
.. group-tab:: c
.. code:: c
class Exec
=============
-.. doxygenclass:: simgrid::s4u::Exec
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Exec
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Exec
Basic management
----------------
from simgrid import Exec
- .. autoclass:: simgrid.Exec
-
.. group-tab:: C
.. code-block:: C
class Io
===========
-.. doxygenclass:: simgrid::s4u::Io
+.. tabs::
+
+ .. group-tab:: C++
+
+ .. doxygenclass:: simgrid::s4u::Io
+
+ .. group-tab:: Python
+
+ .. autoclass:: simgrid.Io
Basic management
----------------
static py::object pyForcefulKillEx(py::register_exception<simgrid::ForcefulKillException>(m, "ActorKilled"));
/* this_actor namespace */
- m.def_submodule("this_actor", "Bindings of the s4u::this_actor namespace.")
+ m.def_submodule("this_actor", "Bindings of the s4u::this_actor namespace. See the C++ documentation for details.")
.def(
"info", [](const char* s) { XBT_INFO("%s", s); }, "Display a logging message of 'info' priority.")
.def(
"Registers the main function of an actor");
/* Class Netzone */
- py::class_<simgrid::s4u::NetZone, std::unique_ptr<simgrid::s4u::NetZone, py::nodelete>> netzone(m, "NetZone",
- "Networking Zones");
+ py::class_<simgrid::s4u::NetZone, std::unique_ptr<simgrid::s4u::NetZone, py::nodelete>> netzone(
+ m, "NetZone", "Networking Zones. See the C++ documentation for details.");
netzone.def_static("create_full_zone", &simgrid::s4u::create_full_zone, "Creates a zone of type FullZone")
.def_static("create_torus_zone", &simgrid::s4u::create_torus_zone, "Creates a cluster of type Torus")
.def_static("create_fatTree_zone", &simgrid::s4u::create_fatTree_zone, "Creates a cluster of type Fat-Tree")
const std::pair<unsigned int, unsigned int>&, unsigned int>());
/* Class Host */
- py::class_<simgrid::s4u::Host, std::unique_ptr<Host, py::nodelete>> host(m, "Host", "Simulated host");
+ py::class_<simgrid::s4u::Host, std::unique_ptr<Host, py::nodelete>> host(
+ m, "Host", "Simulated host. See the C++ documentation for details.");
host.def("by_name", &Host::by_name, "Retrieves a host from its name, or die")
.def("get_pstate_count", &Host::get_pstate_count, "Retrieve the count of defined pstate levels")
.def("get_pstate_speed", &Host::get_pstate_speed, "Retrieve the maximal speed at the given pstate")
.export_values();
/* Class Disk */
- py::class_<simgrid::s4u::Disk, std::unique_ptr<simgrid::s4u::Disk, py::nodelete>> disk(m, "Disk", "Simulated disk");
+ py::class_<simgrid::s4u::Disk, std::unique_ptr<simgrid::s4u::Disk, py::nodelete>> disk(
+ m, "Disk", "Simulated disk. See the C++ documentation for details.");
disk.def("read", py::overload_cast<sg_size_t, double>(&simgrid::s4u::Disk::read, py::const_),
py::call_guard<py::gil_scoped_release>(), "Read data from disk", py::arg("size"), py::arg("priority") = 1)
.def("write", py::overload_cast<sg_size_t, double>(&simgrid::s4u::Disk::write, py::const_),
netpoint(m, "NetPoint", "NetPoint object");
/* Class Link */
- py::class_<simgrid::s4u::Link, std::unique_ptr<simgrid::s4u::Link, py::nodelete>> link(m, "Link", "Network link");
+ py::class_<simgrid::s4u::Link, std::unique_ptr<simgrid::s4u::Link, py::nodelete>> link(
+ m, "Link", "Network link. See the C++ documentation for details.");
link.def("set_latency", py::overload_cast<const std::string&>(&simgrid::s4u::Link::set_latency),
py::call_guard<py::gil_scoped_release>(), "Set the latency")
.def("set_latency", py::overload_cast<double>(&simgrid::s4u::Link::set_latency),
.def("get_link_down", &simgrid::s4u::SplitDuplexLink::get_link_down, "Get link direction down");
/* Class Mailbox */
- py::class_<simgrid::s4u::Mailbox, std::unique_ptr<Mailbox, py::nodelete>>(m, "Mailbox", "Mailbox")
+ py::class_<simgrid::s4u::Mailbox, std::unique_ptr<Mailbox, py::nodelete>>(
+ m, "Mailbox", "Mailbox. See the C++ documentation for details.")
.def(
"__str__", [](const Mailbox* self) { return std::string("Mailbox(") + self->get_cname() + ")"; },
"Textual representation of the Mailbox`")
"Get python object after async communication in receiver side");
/* Class Comm */
- py::class_<simgrid::s4u::Comm, simgrid::s4u::CommPtr>(m, "Comm", "Communication")
+ py::class_<simgrid::s4u::Comm, simgrid::s4u::CommPtr>(m, "Comm",
+ "Communication. See the C++ documentation for details.")
.def("test", &simgrid::s4u::Comm::test, py::call_guard<py::gil_scoped_release>(),
"Test whether the communication is terminated.")
.def("wait", &simgrid::s4u::Comm::wait, py::call_guard<py::gil_scoped_release>(),
"Block until the completion of any communication in the list and return the index of the terminated one.");
/* Class Io */
- py::class_<simgrid::s4u::Io, simgrid::s4u::IoPtr>(m, "Io", "I/O activities")
+ py::class_<simgrid::s4u::Io, simgrid::s4u::IoPtr>(m, "Io", "I/O activities. See the C++ documentation for details.")
.def("test", &simgrid::s4u::Io::test, py::call_guard<py::gil_scoped_release>(),
"Test whether the I/O is terminated.")
.def("wait", &simgrid::s4u::Io::wait, py::call_guard<py::gil_scoped_release>(),
"Block until the completion of any I/O in the list and return the index of the terminated one.");
/* Class Exec */
- py::class_<simgrid::s4u::Exec, simgrid::s4u::ExecPtr>(m, "Exec", "Execution")
+ py::class_<simgrid::s4u::Exec, simgrid::s4u::ExecPtr>(m, "Exec", "Execution. See the C++ documentation for details.")
.def_property_readonly(
"remaining",
[](simgrid::s4u::ExecPtr self) {
/* Class Actor */
py::class_<simgrid::s4u::Actor, ActorPtr>(m, "Actor",
"An actor is an independent stream of execution in your distributed "
- "application")
+ "application. See the C++ documentation for details.")
.def(
"create",
[](py::str name, Host* h, py::object fun, py::args args) {